Commit a197df2c authored by David Redondo's avatar David Redondo 🏎
Browse files

Use the same configs for watching and reading

KColorScheme uses KSharedConfig::openConfig() when no config is specified,
we were watching a KSharedConfig::openConfig("kdeglobals") which seemingly
is not updated instantly because it technically is different even though
effectively it's the same config. Watching the same configs solves the theme
not updating when the global theme is switched
BUG:421745
FIXED-IN:5.21
parent 48e4110e
......@@ -23,7 +23,7 @@
#include "configvalueprovider.h"
ConfigValueProvider::ConfigValueProvider() :
kdeglobalsConfig(KSharedConfig::openConfig(QStringLiteral("kdeglobals"))),
kdeglobalsConfig(KSharedConfig::openConfig()),
inputConfig(KSharedConfig::openConfig(QStringLiteral("kcminputrc"))),
kwinConfig(KSharedConfig::openConfig(QStringLiteral("kwinrc")))
{
......
......@@ -21,7 +21,7 @@ GtkConfig::GtkConfig(QObject *parent, const QVariantList&) :
KDEDModule(parent),
configValueProvider(new ConfigValueProvider()),
themePreviewer(new ThemePreviewer(this)),
kdeglobalsConfigWatcher(KConfigWatcher::create(KSharedConfig::openConfig(QStringLiteral("kdeglobals")))),
kdeglobalsConfigWatcher(KConfigWatcher::create(KSharedConfig::openConfig())),
kwinConfigWatcher(KConfigWatcher::create(KSharedConfig::openConfig(QStringLiteral("kwinrc")))),
kcminputConfigWatcher(KConfigWatcher::create(KSharedConfig::openConfig(QStringLiteral("kcminputrc")))),
breezeConfigWatcher(KConfigWatcher::create(KSharedConfig::openConfig(QStringLiteral("breezerc"))))
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment