C++ (Qt)bool sStopped(){ stoppedMutex.lock(); return stopped; stoppedMutex.unLock(); }
C++ (Qt)bool sStopped(){ QMutexLocker lock( &stoppedMutex ); return stopped;}
C++ (Qt)bool isStopped(){ QMutexLocker lock( &stoppedMutex ); return stopped;}
C++ (Qt)void myThread::run() { QMutex m; m.lock(); for(int i = 0; i <= dataSize; ++i) { if (i) waitCondition.wait(&m); if (i < dataSize) obj->func(i); } m.unlock();}