summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms
diff options
context:
space:
mode:
authorMaurice Kalinowski <maurice.kalinowski@qt.io>2017-04-07 11:00:54 +0200
committerMaurice Kalinowski <maurice.kalinowski@qt.io>2017-04-10 07:02:06 +0000
commit45862976b7566d416aff887b74eb60cb039a3dd6 (patch)
tree4315fb78bb2a3213570eee6b6af61d83e888c0b8 /src/plugins/platforms
parent43a5fe258b7f48baad69ac040f395cb597022fa9 (diff)
winrt: Fix build for Windows 10 Creators Update
Phone specific UI colors have been removed from the windows headers. Continue to use the enum values does not gain anything as the native calls return errors for those. Actually they did that already with 14393. Change-Id: I4b04d3af319766216ae7c550af704aab488c1d15 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Diffstat (limited to 'src/plugins/platforms')
-rw-r--r--src/plugins/platforms/winrt/qwinrttheme.cpp3
-rw-r--r--src/plugins/platforms/winrt/winrt.pro1
2 files changed, 4 insertions, 0 deletions
diff --git a/src/plugins/platforms/winrt/qwinrttheme.cpp b/src/plugins/platforms/winrt/qwinrttheme.cpp
index 6b35bde83e..5696ae7a10 100644
--- a/src/plugins/platforms/winrt/qwinrttheme.cpp
+++ b/src/plugins/platforms/winrt/qwinrttheme.cpp
@@ -146,6 +146,8 @@ static void nativeColorSettings(QPalette &p)
if (uiColorSettings(L"Hotlight", UIElementType_Hotlight, &color))
p.setColor(QPalette::BrightText, fromColor(color));
+ // Starting with SDK 15063 those have been removed.
+#ifndef QT_WINRT_DISABLE_PHONE_COLORS
//Phone related
if (uiColorSettings(L"PopupBackground", UIElementType_PopupBackground, &color)) {
p.setColor(QPalette::ToolTipBase, fromColor(color));
@@ -186,6 +188,7 @@ static void nativeColorSettings(QPalette &p)
if (uiColorSettings(L"TextContrastWithHigh", UIElementType_TextContrastWithHigh, &color))
p.setColor(QPalette::BrightText, fromColor(color));
+#endif // QT_WINRT_DISABLE_PHONE_COLORS
}
QWinRTTheme::QWinRTTheme()
diff --git a/src/plugins/platforms/winrt/winrt.pro b/src/plugins/platforms/winrt/winrt.pro
index 35801fdacc..02a848b03f 100644
--- a/src/plugins/platforms/winrt/winrt.pro
+++ b/src/plugins/platforms/winrt/winrt.pro
@@ -51,6 +51,7 @@ OTHER_FILES += winrt.json
WINRT_SDK_VERSION_STRING = $$(UCRTVersion)
WINRT_SDK_VERSION = $$member($$list($$split(WINRT_SDK_VERSION_STRING, .)), 2)
lessThan(WINRT_SDK_VERSION, 14322): DEFINES += QT_WINRT_LIMITED_DRAGANDDROP
+greaterThan(WINRT_SDK_VERSION, 14393): DEFINES += QT_WINRT_DISABLE_PHONE_COLORS
contains(DEFINES, QT_NO_DRAGANDDROP) {
SOURCES -= qwinrtdrag.cpp