committed by
Chris Rizzitello
parent
3ed0915b57
commit
d2bf5e63e4
@ -2,6 +2,7 @@
|
||||
|
||||
The search order for a setting file is:
|
||||
1. `<install-path>/settings/Deskflow.conf`
|
||||
1. `<XDG_CONFIG_HOME>/Deskflow/Deskflow.conf`
|
||||
1. A user settings file
|
||||
1. A system settings file
|
||||
|
||||
|
||||
@ -40,7 +40,9 @@ Settings::Settings(QObject *parent) : QObject(parent)
|
||||
if (QFile(m_portableSettingsFile).exists()) {
|
||||
fileToLoad = m_portableSettingsFile;
|
||||
} else {
|
||||
if (QFile(UserSettingFile).exists())
|
||||
if (!qEnvironmentVariable("XDG_CONFIG_HOME").isEmpty())
|
||||
fileToLoad = QStringLiteral("%1/%2/%2.conf").arg(qEnvironmentVariable("XDG_CONFIG_HOME"), kAppName);
|
||||
else if (QFile(UserSettingFile).exists())
|
||||
fileToLoad = UserSettingFile;
|
||||
else if (QFile(SystemSettingFile).exists())
|
||||
fileToLoad = SystemSettingFile;
|
||||
|
||||
Reference in New Issue
Block a user