fix(@desktop/systemtrayicon): using proper QApplication class

This commit is contained in:
Andrei Smirnov 2021-09-14 17:55:08 +03:00 committed by Michał
parent e7ba842662
commit 15b44e7b8f
1 changed files with 3 additions and 3 deletions

View File

@ -128,8 +128,8 @@ char *dos_qcoreapplication_application_dir_path()
void dos_qapplication_enable_hdpi(const char *uiScaleFilePath)
{
QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
QGuiApplication::setHighDpiScaleFactorRoundingPolicy(Qt::HighDpiScaleFactorRoundingPolicy::PassThrough);
QApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
QApplication::setHighDpiScaleFactorRoundingPolicy(Qt::HighDpiScaleFactorRoundingPolicy::PassThrough);
QFile scaleFile(QString::fromUtf8(uiScaleFilePath));
if (scaleFile.open(QIODevice::ReadOnly)) {
@ -140,7 +140,7 @@ void dos_qapplication_enable_hdpi(const char *uiScaleFilePath)
void dos_qapplication_initialize_opengl()
{
QCoreApplication::setAttribute(Qt::AA_ShareOpenGLContexts);
QApplication::setAttribute(Qt::AA_ShareOpenGLContexts);
}
void dos_qguiapplication_create()