Lines 6-33
Link Here
|
6 |
With 0a93db4d82c051164923a10e4382b12de9049b45 ("Unify application |
6 |
With 0a93db4d82c051164923a10e4382b12de9049b45 ("Unify application |
7 |
palette handling between QGuiApplication and QApplication") |
7 |
palette handling between QGuiApplication and QApplication") |
8 |
QApplicationPrivate::setSystemPalette is no longer used and necessary. |
8 |
QApplicationPrivate::setSystemPalette is no longer used and necessary. |
9 |
--- |
9 |
--- src/plugins/styles/gtk2/qgtkstyle.cpp.orig 2017-03-11 09:23:02 UTC |
10 |
src/plugins/styles/gtk2/qgtkstyle.cpp | 2 ++ |
|
|
11 |
src/plugins/styles/gtk2/qgtkstyle_p.cpp | 2 ++ |
12 |
2 files changed, 4 insertions(+) |
13 |
|
14 |
diff --git a/src/plugins/styles/gtk2/qgtkstyle.cpp b/src/plugins/styles/gtk2/qgtkstyle.cpp |
15 |
index 36169c9..2544593 100644 |
16 |
--- src/plugins/styles/gtk2/qgtkstyle.cpp |
17 |
+++ src/plugins/styles/gtk2/qgtkstyle.cpp |
10 |
+++ src/plugins/styles/gtk2/qgtkstyle.cpp |
18 |
@@ -440,7 +440,9 @@ void QGtkStyle::polish(QApplication *app) |
11 |
@@ -440,7 +440,11 @@ void QGtkStyle::polish(QApplication *app) |
19 |
// not supported as these should be entirely determined by |
12 |
// not supported as these should be entirely determined by |
20 |
// current Gtk settings |
13 |
// current Gtk settings |
21 |
if (app->desktopSettingsAware() && d->isThemeAvailable()) { |
14 |
if (app->desktopSettingsAware() && d->isThemeAvailable()) { |
22 |
+#if QT_VERSION < QT_VERSION_CHECK(5, 15, 0) |
15 |
+#if QT_VERSION < QT_VERSION_CHECK(5, 15, 0) |
23 |
QApplicationPrivate::setSystemPalette(standardPalette()); |
16 |
QApplicationPrivate::setSystemPalette(standardPalette()); |
|
|
17 |
+#else |
18 |
+ QApplication::setPalette(standardPalette()); |
24 |
+#endif |
19 |
+#endif |
25 |
QApplicationPrivate::setSystemFont(d->getThemeFont()); |
20 |
QApplicationPrivate::setSystemFont(d->getThemeFont()); |
26 |
d->applyCustomPaletteHash(); |
21 |
d->applyCustomPaletteHash(); |
27 |
if (!d->isKDE4Session()) |
22 |
if (!d->isKDE4Session()) |
28 |
diff --git a/src/plugins/styles/gtk2/qgtkstyle_p.cpp b/src/plugins/styles/gtk2/qgtkstyle_p.cpp |
23 |
src/plugins/styles/gtk2/qgtkstyle.cpp | 2 ++ |
29 |
index e57b3d8..e71beb0 100644 |
24 |
src/plugins/styles/gtk2/qgtkstyle_p.cpp | 2 ++ |
30 |
--- src/plugins/styles/gtk2/qgtkstyle_p.cpp |
25 |
2 files changed, 4 insertions(+) |
|
|
26 |
|
27 |
--- src/plugins/styles/gtk2/qgtkstyle_p.cpp.orig 2017-03-11 09:23:02 UTC |
31 |
+++ src/plugins/styles/gtk2/qgtkstyle_p.cpp |
28 |
+++ src/plugins/styles/gtk2/qgtkstyle_p.cpp |
32 |
@@ -508,7 +508,9 @@ void QGtkStyleUpdateScheduler::updateTheme() |
29 |
@@ -508,7 +508,9 @@ void QGtkStyleUpdateScheduler::updateTheme() |
33 |
if (oldTheme != QGtkStylePrivate::getThemeName()) { |
30 |
if (oldTheme != QGtkStylePrivate::getThemeName()) { |
Lines 39-43
Link Here
|
39 |
QApplication::setPalette(newPalette); |
36 |
QApplication::setPalette(newPalette); |
40 |
if (!QGtkStylePrivate::instances.isEmpty()) { |
37 |
if (!QGtkStylePrivate::instances.isEmpty()) { |
41 |
QGtkStylePrivate::instances.last()->initGtkWidgets(); |
38 |
QGtkStylePrivate::instances.last()->initGtkWidgets(); |
42 |
-- |
|
|
43 |
2.26.2 |