1
0
mirror of https://github.com/TomHarte/CLK.git synced 2025-07-24 07:24:13 +00:00

Makes more failing attempts at a clean shutdown.

This commit is contained in:
Thomas Harte
2020-06-15 00:00:44 -04:00
parent ac732e2e7b
commit 902b33d25d
3 changed files with 6 additions and 5 deletions

View File

@@ -13,7 +13,7 @@ Timer::Timer(QObject *parent) : QObject(parent) {
timer = std::make_unique<QTimer>();
timer->setInterval(1);
connect(timer.get(), SIGNAL(timeout()), this, SLOT(tick()), Qt::DirectConnection);
connect(timer.get(), &QTimer::timeout, this, &Timer::tick, Qt::DirectConnection);
timer->start();
});
}
@@ -35,6 +35,6 @@ void Timer::tick() {
}
Timer::~Timer() {
QMetaObject::invokeMethod(timer.get(), "stop", Qt::QueuedConnection);
QMetaObject::invokeMethod(timer.get(), "stop", Qt::BlockingQueuedConnection);
thread.stop();
}