summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMorph <39850852+Morph1984@users.noreply.github.com>2021-08-03 05:58:41 +0200
committerGitHub <noreply@github.com>2021-08-03 05:58:41 +0200
commitd16a337d98979fd7bdda2a7b0482d5e0f5c76d22 (patch)
treebcf275111b058118f5904c3005b1b7ee5871fc6c
parentMerge pull request #6801 from spholz/spholz-patch-1 (diff)
parentconfig: Only read/write current_user on global config (diff)
downloadyuzu-d16a337d98979fd7bdda2a7b0482d5e0f5c76d22.tar
yuzu-d16a337d98979fd7bdda2a7b0482d5e0f5c76d22.tar.gz
yuzu-d16a337d98979fd7bdda2a7b0482d5e0f5c76d22.tar.bz2
yuzu-d16a337d98979fd7bdda2a7b0482d5e0f5c76d22.tar.lz
yuzu-d16a337d98979fd7bdda2a7b0482d5e0f5c76d22.tar.xz
yuzu-d16a337d98979fd7bdda2a7b0482d5e0f5c76d22.tar.zst
yuzu-d16a337d98979fd7bdda2a7b0482d5e0f5c76d22.zip
-rw-r--r--src/yuzu/configuration/config.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/yuzu/configuration/config.cpp b/src/yuzu/configuration/config.cpp
index 2b20fca8a..380379eb4 100644
--- a/src/yuzu/configuration/config.cpp
+++ b/src/yuzu/configuration/config.cpp
@@ -873,10 +873,6 @@ void Config::ReadShortcutValues() {
void Config::ReadSystemValues() {
qt_config->beginGroup(QStringLiteral("System"));
- ReadBasicSetting(Settings::values.current_user);
- Settings::values.current_user = std::clamp<int>(Settings::values.current_user.GetValue(), 0,
- Service::Account::MAX_USERS - 1);
-
ReadGlobalSetting(Settings::values.language_index);
ReadGlobalSetting(Settings::values.region_index);
@@ -897,6 +893,10 @@ void Config::ReadSystemValues() {
}
if (global) {
+ ReadBasicSetting(Settings::values.current_user);
+ Settings::values.current_user = std::clamp<int>(Settings::values.current_user.GetValue(), 0,
+ Service::Account::MAX_USERS - 1);
+
const auto custom_rtc_enabled =
ReadSetting(QStringLiteral("custom_rtc_enabled"), false).toBool();
if (custom_rtc_enabled) {
@@ -1406,7 +1406,6 @@ void Config::SaveShortcutValues() {
void Config::SaveSystemValues() {
qt_config->beginGroup(QStringLiteral("System"));
- WriteBasicSetting(Settings::values.current_user);
WriteGlobalSetting(Settings::values.language_index);
WriteGlobalSetting(Settings::values.region_index);
WriteGlobalSetting(Settings::values.time_zone_index);
@@ -1418,6 +1417,8 @@ void Config::SaveSystemValues() {
0, Settings::values.rng_seed.UsingGlobal());
if (global) {
+ WriteBasicSetting(Settings::values.current_user);
+
WriteSetting(QStringLiteral("custom_rtc_enabled"), Settings::values.custom_rtc.has_value(),
false);
WriteSetting(QStringLiteral("custom_rtc"),