Commit 5f9243a8 authored by David Edmundson's avatar David Edmundson

Fix colours not updating in systemsettings

Summary:
(after a lot of looking, it turns it's out not a bug in the QQC desktop
style)

KSharedConfig::openConfig() opens the config based on the app name.

The app name comes from the exec name, or
KAboutData::setApplicationData.
setApplicationData only works on an existing qApp.

This means the QPT loaded in the QApp uses the wrong config.
The effect is minimal because most stuff is in kdeglobals, but it means
the KSharedConfigPtr is not shared with the one used elsewhere in the
app. This is wasteful, but also means the QPT calling
reparseConfiguration doesn't take effect, leading to colours not being
dynamically updated

Reviewers: #plasma, mart

Reviewed By: #plasma, mart

Subscribers: ngraham, plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D8399
parent f89baf43
......@@ -29,6 +29,9 @@
int main( int argc, char *argv[] )
{
//exec is systemsettings5, but we need the QPT to use the right config from the qApp constructor
//which is before KAboutData::setApplicationData
QCoreApplication::setApplicationName("systemsettings");
SystemSettingsApp application(argc, argv);
KLocalizedString::setApplicationDomain("systemsettings");
......
Markdown is supported
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