c++ - QThreads interruption with slots and signals -
i have class contains qthread
. in initialization function of class thread should started. works correct. in thread there have while(bool certaincondition){}
certaincondition
should changed signal/slot connection.
the problem during while running signal/slot not opened.
you not running event loop in thread, or blocking long time in while-loop. slot cannot called until have returned control event loop, happen after have finished while-loop.
as workaround, can try calling qcoreapplication::processevents() inside while-loop.
Comments
Post a Comment