summaryrefslogtreecommitdiffstats
path: root/src/widgets/dialogs/qcolordialog.cpp
diff options
context:
space:
mode:
authorTor Arne Vestbø <tor.arne.vestbo@qt.io>2019-05-16 14:51:42 +0200
committerTor Arne Vestbø <tor.arne.vestbo@qt.io>2019-05-16 14:51:42 +0200
commit5e743adc20254b0a5b8e3aa20be1f03d4d07424e (patch)
treee95725c6f84668c6c5d540ed6f701a77ea02c0c4 /src/widgets/dialogs/qcolordialog.cpp
parent387691498a26573aeeb7c64b665f84f9e95dc128 (diff)
Don't try to retranslate strings for native color dialogs
If the native color dialog is in use we haven't created any of the widgets and will crash when trying to update them. Change-Id: I6c43cc47359110c3b9db7cacb62581446cc6f7a3 Fixes: QTBUG-75858 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Diffstat (limited to 'src/widgets/dialogs/qcolordialog.cpp')
-rw-r--r--src/widgets/dialogs/qcolordialog.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/widgets/dialogs/qcolordialog.cpp b/src/widgets/dialogs/qcolordialog.cpp
index 7132bb3297..29178c02c3 100644
--- a/src/widgets/dialogs/qcolordialog.cpp
+++ b/src/widgets/dialogs/qcolordialog.cpp
@@ -1858,6 +1858,9 @@ void QColorDialogPrivate::_q_addCustom()
void QColorDialogPrivate::retranslateStrings()
{
+ if (nativeDialogInUse)
+ return;
+
if (!smallDisplay) {
lblBasicColors->setText(QColorDialog::tr("&Basic colors"));
lblCustomColors->setText(QColorDialog::tr("&Custom colors"));