diff options
author | Yuhang Zhao <2546789017@qq.com> | 2021-07-29 14:58:34 +0800 |
---|---|---|
committer | Yuhang Zhao <2546789017@qq.com> | 2021-11-24 09:16:38 +0800 |
commit | e75b1dfe380e854ed5ceaf5933740e3759a22aaf (patch) | |
tree | 85f20bfeab34768a1eca2675312aa909e44dc14a /src/plugins/platforms/windows/qwindowstheme.cpp | |
parent | f5f7f78766d62b7192b98b96bbd68dab1961e54e (diff) |
Windows QPA: Further cleanup of pre-Win10 code
Mostly a removal of dynamically loaded Win32 APIs.
Since Qt 6's minimum supported platform is Win10 1809
(10.0.17763, code name RS5), all these functions will
be available and no need to resolve them at run-time.
Things not remove:
WinTab functions in "qwindowstabletsupport.cpp".
Not my familiar area, so not touch it.
Pick-to: 6.2
Task-number: QTBUG-84432
Change-Id: I7ad6c3bc8376f6c0e3ac90f34e22f7628efeb694
Reviewed-by: André de la Rocha <andre.rocha@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Diffstat (limited to 'src/plugins/platforms/windows/qwindowstheme.cpp')
-rw-r--r-- | src/plugins/platforms/windows/qwindowstheme.cpp | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/plugins/platforms/windows/qwindowstheme.cpp b/src/plugins/platforms/windows/qwindowstheme.cpp index 85b6c30086..9ee6bbd79a 100644 --- a/src/plugins/platforms/windows/qwindowstheme.cpp +++ b/src/plugins/platforms/windows/qwindowstheme.cpp @@ -63,7 +63,6 @@ #include <QtCore/qcoreapplication.h> #include <QtCore/qdebug.h> #include <QtCore/qtextstream.h> -#include <QtCore/qoperatingsystemversion.h> #include <QtCore/qsysinfo.h> #include <QtCore/qcache.h> #include <QtCore/qthread.h> @@ -1053,9 +1052,7 @@ bool QWindowsTheme::useNativeMenus() bool QWindowsTheme::queryDarkMode() { - if (QOperatingSystemVersion::current() - < QOperatingSystemVersion(QOperatingSystemVersion::Windows, 10, 0, 17763) - || queryHighContrast()) { + if (queryHighContrast()) { return false; } const auto setting = QWinRegistryKey(HKEY_CURRENT_USER, LR"(Software\Microsoft\Windows\CurrentVersion\Themes\Personalize)") |