summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVolker Hilsheimer <[email protected]>2024-05-02 21:45:16 +0200
committerTor Arne Vestbø <[email protected]>2024-05-03 12:04:51 +0000
commitcee94658d686d22d28a1fef849eb916e494e67e2 (patch)
tree1d5e713c5467f303cb04d478b3eb4246672e89a5
parent2c5f5bf2e8843d8c88c3ece9bd93c567fd74d3ae (diff)
Windows: handle theme changes synchronously when settings change
The handleSettingsChange handler is usually already executed through the event loop. And if it is called directly e.g. when changing settings programmatically, then all side effects of the change should be in effect immediately. Task-number: QTBUG-124490 Change-Id: I243772860b1137ef9fe712c4b0d1c88593d2bdb4 Reviewed-by: Tor Arne Vestbø <[email protected]> Reviewed-by: Oliver Wolff <[email protected]>
-rw-r--r--src/plugins/platforms/windows/qwindowstheme.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/platforms/windows/qwindowstheme.cpp b/src/plugins/platforms/windows/qwindowstheme.cpp
index a2224b1eacb..e8a324aedb9 100644
--- a/src/plugins/platforms/windows/qwindowstheme.cpp
+++ b/src/plugins/platforms/windows/qwindowstheme.cpp
@@ -561,7 +561,7 @@ void QWindowsTheme::handleSettingsChanged()
integration->updateApplicationBadge();
if (integration->darkModeHandling().testFlag(QWindowsApplication::DarkModeStyle)) {
QWindowsTheme::instance()->refresh();
- QWindowSystemInterface::handleThemeChange();
+ QWindowSystemInterface::handleThemeChange<QWindowSystemInterface::SynchronousDelivery>();
}
if (colorSchemeChanged) {
for (QWindowsWindow *w : std::as_const(QWindowsContext::instance()->windows()))