summaryrefslogtreecommitdiffstats
path: root/src/widgets/kernel/qapplication.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/widgets/kernel/qapplication.cpp')
-rw-r--r--src/widgets/kernel/qapplication.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/widgets/kernel/qapplication.cpp b/src/widgets/kernel/qapplication.cpp
index 28575a20f5..ef76265f8b 100644
--- a/src/widgets/kernel/qapplication.cpp
+++ b/src/widgets/kernel/qapplication.cpp
@@ -633,7 +633,7 @@ static void setPossiblePalette(const QPalette *palette, const char *className)
{
if (palette == 0)
return;
- QApplicationPrivate::setPalette_helper(*palette, className, false);
+ QApplicationPrivate::setPalette_helper(*palette, className);
}
void QApplicationPrivate::initializeWidgetPaletteHash()
@@ -1363,7 +1363,7 @@ QPalette QApplication::palette(const char *className)
return QGuiApplication::palette();
}
-void QApplicationPrivate::setPalette_helper(const QPalette &palette, const char* className, bool clearWidgetPaletteHash)
+void QApplicationPrivate::setPalette_helper(const QPalette &palette, const char* className)
{
QPalette pal = palette;
@@ -1380,8 +1380,7 @@ void QApplicationPrivate::setPalette_helper(const QPalette &palette, const char*
if (!widgetPalettes.isEmpty()) {
all = true;
- if (clearWidgetPaletteHash)
- widgetPalettes.clear();
+ widgetPalettes.clear();
}
} else {
widgetPalettes.insert(className, pal);
@@ -1416,7 +1415,7 @@ void QApplicationPrivate::setPalette_helper(const QPalette &palette, const char*
void QApplication::setPalette(const QPalette &palette, const char* className)
{
- QApplicationPrivate::setPalette_helper(palette, className, /*clearWidgetPaletteHash=*/ true);
+ QApplicationPrivate::setPalette_helper(palette, className);
}