summaryrefslogtreecommitdiffstats
path: root/src/corelib/platform
diff options
context:
space:
mode:
authorYuhang Zhao <2546789017@qq.com>2023-01-25 09:03:15 +0800
committerYuhang Zhao <yuhangzhao@deepin.org>2023-02-07 17:59:59 +0000
commitad7227ada177dec4e61e8bbc51dd70f00a6e3d15 (patch)
tree5c6aa254cbea39499f6611df58c367dfd4055bbb /src/corelib/platform
parentd141d6894960dba7c62d67400a31a49a4abcdb08 (diff)
Use qt_winrtbase_p.h workaround in more places
This patch addresses the following issues: (1) some places are still using the original workaround, replace them with the new qt_winrtbase_p.h workaround. (2) add more comment to let people know how to workaround other cppwinrt issues (it was a common issue for many years and may be fixed upstream recently, but let's at least document it in case the user is still using old version cppwinrt). Amends commit b2c1237b4512480a17009afe1981af02c2a9869e Pick-to: 6.5 6.4 Change-Id: Ife676f41739bbe69d9fb23bf5758be4b1fab4855 Reviewed-by: MÃ¥rten Nordheim <marten.nordheim@qt.io> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Diffstat (limited to 'src/corelib/platform')
-rw-r--r--src/corelib/platform/windows/qt_winrtbase_p.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/corelib/platform/windows/qt_winrtbase_p.h b/src/corelib/platform/windows/qt_winrtbase_p.h
index 36551b7faf..fb7366f93d 100644
--- a/src/corelib/platform/windows/qt_winrtbase_p.h
+++ b/src/corelib/platform/windows/qt_winrtbase_p.h
@@ -18,8 +18,8 @@
#include <QtCore/qglobal.h>
#if QT_CONFIG(cpp_winrt)
-#include <winrt/base.h>
-#include <QtCore/private/qfactorycacheregistration_p.h>
+# include <winrt/base.h>
+# include <QtCore/private/qfactorycacheregistration_p.h>
// Workaround for Windows SDK bug.
// See https://github.com/microsoft/Windows.UI.Composition-Win32-Samples/issues/47
namespace winrt::impl
@@ -27,6 +27,8 @@ namespace winrt::impl
template <typename Async>
auto wait_for(Async const& async, Windows::Foundation::TimeSpan const& timeout);
}
+// See https://learn.microsoft.com/en-us/windows/uwp/cpp-and-winrt-apis/faq#how-do-i-resolve-ambiguities-with-getcurrenttime-and-or-try-
+// for more workarounds.
#endif // QT_CONFIG(cpp/winrt)
#endif // QT_WINRTBASE_P_H