From 8358d7f8766057bfc0c8bea4823d23af16b67014 Mon Sep 17 00:00:00 2001 From: wmayer Date: Thu, 3 Jan 2019 16:14:12 +0100 Subject: [PATCH] Qt5: don't use native color dialog --- src/Gui/Widgets.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/Gui/Widgets.cpp b/src/Gui/Widgets.cpp index 5aa36cf2afe9..461d8ff992fb 100644 --- a/src/Gui/Widgets.cpp +++ b/src/Gui/Widgets.cpp @@ -748,6 +748,9 @@ void ColorButton::onChooseColor() #endif QColor currentColor = d->col; QColorDialog cd(d->col, this); +#if QT_VERSION >= 0x050000 + cd.setOptions(QColorDialog::DontUseNativeDialog); +#endif if (d->autoChange) { connect(&cd, SIGNAL(currentColorChanged(const QColor &)), @@ -771,6 +774,9 @@ void ColorButton::onChooseColor() if (d->cd.isNull()) { d->old = d->col; d->cd = new QColorDialog(d->col, this); +#if QT_VERSION >= 0x050000 + d->cd->setOptions(QColorDialog::DontUseNativeDialog); +#endif d->cd->setAttribute(Qt::WA_DeleteOnClose); connect(d->cd, SIGNAL(rejected()), this, SLOT(onRejected()));