mirror of
https://github.com/cculianu/Fulcrum.git
synced 2026-08-15 12:50:49 +02:00
API nit: Use Util::AsyncOnObject everywhere instead of QTimer::singleShot
This is just to make the API easier to follow. Also cleaned up AsyncOnObject to not default to caarse timer unless the interval is >2000 msec. Also we use QMetaObject::invokeMethod() directly by default if the AsyncOnObjectCall() has when_ms <= 0 (default). This should have no real observable change on app behavior other than being a code cleanup & nit.
This commit is contained in:
parent
92fd99fee8
commit
eba8431a0b
9 changed files with 27 additions and 19 deletions
|
|
@ -780,7 +780,7 @@ Log::~Log()
|
|||
}
|
||||
// Fatal should signal a quit even here
|
||||
if (level == Logger::Level::Fatal && qApp) {
|
||||
QTimer::singleShot(0, qApp, []{ qApp->quit(); });
|
||||
Util::AsyncOnObject(qApp, []{ qApp->quit(); });
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue