summaryrefslogtreecommitdiffstats
path: root/src/frontend_common/config.cpp
diff options
context:
space:
mode:
authorliamwhite <liamwhite@users.noreply.github.com>2024-01-04 21:51:24 +0100
committerGitHub <noreply@github.com>2024-01-04 21:51:24 +0100
commita8f62bff4364b906076dcc4d1306d2f6fe83fc74 (patch)
treed68ec1701f88a720c36ddf3304e9f309d9fee8c9 /src/frontend_common/config.cpp
parentMerge pull request #12571 from t895/apply-orientation-on-start (diff)
parentandroid: Save global config synchronously in onCloseGameFoldersFragment (diff)
downloadyuzu-a8f62bff4364b906076dcc4d1306d2f6fe83fc74.tar
yuzu-a8f62bff4364b906076dcc4d1306d2f6fe83fc74.tar.gz
yuzu-a8f62bff4364b906076dcc4d1306d2f6fe83fc74.tar.bz2
yuzu-a8f62bff4364b906076dcc4d1306d2f6fe83fc74.tar.lz
yuzu-a8f62bff4364b906076dcc4d1306d2f6fe83fc74.tar.xz
yuzu-a8f62bff4364b906076dcc4d1306d2f6fe83fc74.tar.zst
yuzu-a8f62bff4364b906076dcc4d1306d2f6fe83fc74.zip
Diffstat (limited to 'src/frontend_common/config.cpp')
-rw-r--r--src/frontend_common/config.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/frontend_common/config.cpp b/src/frontend_common/config.cpp
index 359a0d267..20de91ff4 100644
--- a/src/frontend_common/config.cpp
+++ b/src/frontend_common/config.cpp
@@ -883,9 +883,10 @@ void Config::WriteSettingGeneric(const Settings::BasicSetting* const setting) {
WriteBooleanSetting(std::string(key).append("\\use_global"), setting->UsingGlobal());
}
if (global || !setting->UsingGlobal()) {
+ auto value = global ? setting->ToStringGlobal() : setting->ToString();
WriteBooleanSetting(std::string(key).append("\\default"),
- setting->ToString() == setting->DefaultToString());
- WriteStringSetting(key, setting->ToString());
+ value == setting->DefaultToString());
+ WriteStringSetting(key, value);
}
} else if (global) {
WriteBooleanSetting(std::string(key).append("\\default"),