c++ - Qt break out of loop in worker class -


I have a working class which is in its thread, different from the GUI thread, inside the worker class, I have a The method in which the du-all loop is included. I am trying to do this so that by clicking on a pushbutton on the GUI, it starts outside the loop. What do I have so far:

  class worker: public quote object {... public slot: zero process (); Private Slots: Wide Cattle Loop () {killLoopFlag = true;} Private: Boole Calendar Flop; }; // And Class Declaration Connect (ui-> StopButton, Signal (Click)), Worker, Slot (Maroop ())); // qDebug confirms that this connection works. Zero process () {killLoopFlag = false; //Solution. Bull Mar was laughing flag before Do {// stuff QApplication :: processEvents (); If (killLoopFlag == true) {brake;}} while (// other condition);  

killLoopFlag is not set to the correct method () method What am I missing?

Edit: KillLoopFlag was retrieved at the beginning of the process () . bool was removed and all is well


Comments