可使用互斥量的方式,来进行暂停和开继续this
.h文件thread
#include <QMutex>文件
QMutex _mutex;void
.cpp文件
//暂停
void mythread::pause(){ this->_mutex.lock();}
//开始void mythread::resume(){ this-> _mutex.unlock();}