fix: make sure client, server and core init a qApp for Setting's to find the app path with

fixes #8534
This commit is contained in:
sithlord48 2025-04-23 21:23:13 -04:00 committed by Nick Bolton
parent 285abc7bb7
commit 793ea5f81c
3 changed files with 15 additions and 0 deletions

View file

@ -13,11 +13,16 @@
#if SYSAPI_WIN32
#include "arch/win32/ArchMiscWindows.h"
#include <QCoreApplication>
#endif
int main(int argc, char **argv)
{
#if SYSAPI_WIN32
// HACK to make sure settings gets the correct qApp path
QCoreApplication m(argc, argv);
m.deleteLater();
ArchMiscWindows::guardRuntimeVersion();
// record window instance for tray icon, etc

View file

@ -14,6 +14,7 @@
#if SYSAPI_WIN32
#include "arch/win32/ArchMiscWindows.h"
#include <QCoreApplication>
#endif
#include <iostream>
@ -39,6 +40,10 @@ bool isClient(int argc, char **argv)
int main(int argc, char **argv)
{
#if SYSAPI_WIN32
// HACK to make sure settings gets the correct qApp path
QCoreApplication m(argc, argv);
m.deleteLater();
ArchMiscWindows::setInstanceWin32(GetModuleHandle(NULL));
#endif

View file

@ -13,11 +13,16 @@
#if SYSAPI_WIN32
#include "arch/win32/ArchMiscWindows.h"
#include <QCoreApplication>
#endif
int main(int argc, char **argv)
{
#if SYSAPI_WIN32
// HACK to make sure settings gets the correct qApp path
QCoreApplication m(argc, argv);
m.deleteLater();
ArchMiscWindows::guardRuntimeVersion();
// record window instance for tray icon, etc