summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMichael BrĂ¼ning <michael.bruning@qt.io>2022-06-15 22:19:08 +0200
committerMichael BrĂ¼ning <michael.bruning@qt.io>2022-06-19 09:19:57 +0200
commit51b024c53ceb43febbded3c14974e9d8f75c1c11 (patch)
tree9c0dd8ef1d799f9e46c4672551ce4f2668e3a9d9 /src
parent19c6b0a22f20a33c8c1fd4bdea29468fa8b4e10e (diff)
Do not use the native dialog to show the color picker on macOS
With the native dialog, there were either problems with the modality when using it asynchronously or with the life cycle when using it synchronously. Not using the native dialog avoids these problems. Pick-to: 6.4 6.3 Task-number: QTBUG-102099 Change-Id: Icb9a9afda48c47558b8e8ecb6d89adc0961d5063 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'src')
-rw-r--r--src/webenginewidgets/api/qwebengineview.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/webenginewidgets/api/qwebengineview.cpp b/src/webenginewidgets/api/qwebengineview.cpp
index 5fdd995b8..9b8e72ce1 100644
--- a/src/webenginewidgets/api/qwebengineview.cpp
+++ b/src/webenginewidgets/api/qwebengineview.cpp
@@ -565,6 +565,10 @@ void QWebEngineViewPrivate::showColorDialog(
QColorDialog::connect(dialog, SIGNAL(colorSelected(QColor)), dialog, SLOT(deleteLater()));
QColorDialog::connect(dialog, SIGNAL(rejected()), dialog, SLOT(deleteLater()));
+#if defined(Q_OS_MACOS)
+ dialog->setOption(QColorDialog::DontUseNativeDialog);
+#endif
+
dialog->open();
#else
Q_UNUSED(controller);