Fix SingleApplication static functions called from instance

This commit is contained in:
EmmanuelMess
2021-09-09 20:46:13 -03:00
committed by Jonas Kvinge
parent 8ca0b54b18
commit 68c44daef2
7 changed files with 13 additions and 13 deletions

View File

@@ -233,9 +233,9 @@ void WorkerPool<HandlerType>::DoStart() {
executable_path_ = executable_name_;
QStringList search_path;
search_path << qApp->applicationDirPath();
search_path << QCoreApplication::applicationDirPath();
#if defined(Q_OS_MACOS) && defined(USE_BUNDLE)
search_path << qApp->applicationDirPath() + "/" + USE_BUNDLE_DIR;
search_path << QCoreApplication::applicationDirPath() + "/" + USE_BUNDLE_DIR;
#endif
for (const QString &path_prefix : search_path) {

View File

@@ -59,5 +59,5 @@ void TagReaderWorker::MessageArrived(const spb::tagreader::Message &message) {
void TagReaderWorker::DeviceClosed() {
AbstractMessageHandler<spb::tagreader::Message>::DeviceClosed();
qApp->exit();
QCoreApplication::exit();
}