diff options
author | Alessandro Portale <alessandro.portale@qt.io> | 2020-11-18 18:42:27 +0100 |
---|---|---|
committer | Alessandro Portale <alessandro.portale@qt.io> | 2020-11-18 22:08:42 +0000 |
commit | 871c8e3ffd403028b97d7bdd4dc0c7a46d4053e4 (patch) | |
tree | 44d0ce1484530d7750aeec7363d48d055f73cb5a /src/app/main.cpp | |
parent | 30aec822852efd0f4792d1acf1f90f387dedeeb4 (diff) |
Don't access static functions via Utils::HostOsInfo instance
Change-Id: Ic45b8f324cb7c6a4691545fc8d668eed69dfeced
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Diffstat (limited to 'src/app/main.cpp')
-rw-r--r-- | src/app/main.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/app/main.cpp b/src/app/main.cpp index d18502e1f0a..9f540e7279d 100644 --- a/src/app/main.cpp +++ b/src/app/main.cpp @@ -327,12 +327,12 @@ static inline QSettings *userSettings() static void setHighDpiEnvironmentVariable() { - if (Utils::HostOsInfo().isMacHost()) + if (Utils::HostOsInfo::isMacHost()) return; std::unique_ptr<QSettings> settings(createUserSettings()); - const bool defaultValue = Utils::HostOsInfo().isWindowsHost(); + const bool defaultValue = Utils::HostOsInfo::isWindowsHost(); const bool enableHighDpiScaling = settings->value("Core/EnableHighDpiScaling", defaultValue).toBool(); static const char ENV_VAR_QT_DEVICE_PIXEL_RATIO[] = "QT_DEVICE_PIXEL_RATIO"; @@ -540,7 +540,7 @@ int main(int argc, char **argv) QLatin1String(Core::Constants::IDE_CASED_ID)); loadFonts(); - if (Utils::HostOsInfo().isWindowsHost() + if (Utils::HostOsInfo::isWindowsHost() && !qFuzzyCompare(qApp->devicePixelRatio(), 1.0) && QApplication::style()->objectName().startsWith( QLatin1String("windows"), Qt::CaseInsensitive)) { |