QSSASyncProcess修复重复connect导致的触发问题。
parent
43cd74b18f
commit
c1890fb547
5
Qss.cpp
5
Qss.cpp
|
@ -1946,6 +1946,7 @@ void QssMaskWidget::paintEvent(QPaintEvent *event)
|
|||
}
|
||||
|
||||
QSSASyncProcess::QSSASyncProcess(QWidget *parent)
|
||||
:mFirst(true)
|
||||
{
|
||||
this->mParent = parent;
|
||||
}
|
||||
|
@ -1959,9 +1960,11 @@ QSSASyncProcess::~QSSASyncProcess()
|
|||
int QSSASyncProcess::Start(void *p)
|
||||
{
|
||||
this->moveToThread(&mThread);
|
||||
if(mFirst){
|
||||
connect(this, SIGNAL(StartRun(void *)), this, SLOT(Run(void *)));
|
||||
connect(&mThread, &QThread::finished, this, &QObject::deleteLater);
|
||||
|
||||
mFirst = false;
|
||||
}
|
||||
mThread.start();
|
||||
#ifdef QT_NO_EMIT
|
||||
StartRun(p);
|
||||
|
|
Loading…
Reference in New Issue