34 lines
1.1 KiB
Diff
34 lines
1.1 KiB
Diff
From a408cee19e004f1c3e0fea33696fd9a862deb05c Mon Sep 17 00:00:00 2001
|
|
From: tanyulong2021 <tanyulong@kylinos.cn>
|
|
Date: Mon, 1 Aug 2022 11:46:01 +0800
|
|
Subject: [PATCH] add and use attribute of UseHighDpiPixmaps
|
|
|
|
---
|
|
polkit-agent/src/PolkitAgent.cpp | 9 +++++++--
|
|
1 file changed, 7 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/polkit-agent/src/PolkitAgent.cpp b/polkit-agent/src/PolkitAgent.cpp
|
|
index 6966c05..31a234d 100755
|
|
--- a/polkit-agent/src/PolkitAgent.cpp
|
|
+++ b/polkit-agent/src/PolkitAgent.cpp
|
|
@@ -36,9 +36,14 @@ int main(int argc, char *argv[])
|
|
logPrefix = "[ukui-polkit]:";
|
|
qInstallMessageHandler(outputMessage);
|
|
|
|
- qDebug() << "Polkit Agent Started";
|
|
+ qDebug() << "Polkit Agent Started";
|
|
+ #if(QT_VERSION >= QT_VERSION_CHECK(5,6,0))
|
|
+ QApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
|
|
+ QApplication::setAttribute(Qt::AA_UseHighDpiPixmaps);
|
|
+ #endif
|
|
+
|
|
|
|
- QApplication agent(argc, argv);
|
|
+ QApplication agent(argc, argv);
|
|
|
|
QString locale = QLocale::system().name();
|
|
qDebug() << "Language: " <<locale;
|
|
--
|
|
2.33.0
|
|
|