diff options
| author | 2024-02-16 21:07:03 -0500 | |
|---|---|---|
| committer | 2024-02-16 21:07:03 -0500 | |
| commit | dc2c302a84e4757b00c22c4ee0d2e7897840dd38 (patch) | |
| tree | 8eb6f1f35573abd1183a2231b64fbe4b2b271062 | |
| parent | android: Allow SettingsItems to use String or StringRes (diff) | |
| download | yuzu-dc2c302a84e4757b00c22c4ee0d2e7897840dd38.tar.gz yuzu-dc2c302a84e4757b00c22c4ee0d2e7897840dd38.tar.xz yuzu-dc2c302a84e4757b00c22c4ee0d2e7897840dd38.zip | |
config: Reset per-game profile name on load if empty
| -rw-r--r-- | src/frontend_common/config.cpp | 1 | ||||
| -rw-r--r-- | src/yuzu/configuration/qt_config.cpp | 1 | ||||
| -rw-r--r-- | src/yuzu_cmd/sdl_config.cpp | 1 |
3 files changed, 3 insertions, 0 deletions
diff --git a/src/frontend_common/config.cpp b/src/frontend_common/config.cpp index 2bebfeef9..95f8c8c36 100644 --- a/src/frontend_common/config.cpp +++ b/src/frontend_common/config.cpp | |||
| @@ -138,6 +138,7 @@ void Config::ReadPlayerValues(const std::size_t player_index) { | |||
| 138 | if (profile_name.empty()) { | 138 | if (profile_name.empty()) { |
| 139 | // Use the global input config | 139 | // Use the global input config |
| 140 | player = Settings::values.players.GetValue(true)[player_index]; | 140 | player = Settings::values.players.GetValue(true)[player_index]; |
| 141 | player.profile_name = ""; | ||
| 141 | return; | 142 | return; |
| 142 | } | 143 | } |
| 143 | player.profile_name = profile_name; | 144 | player.profile_name = profile_name; |
diff --git a/src/yuzu/configuration/qt_config.cpp b/src/yuzu/configuration/qt_config.cpp index 1051031f2..37951b9c8 100644 --- a/src/yuzu/configuration/qt_config.cpp +++ b/src/yuzu/configuration/qt_config.cpp | |||
| @@ -90,6 +90,7 @@ void QtConfig::ReadQtPlayerValues(const std::size_t player_index) { | |||
| 90 | if (profile_name.empty()) { | 90 | if (profile_name.empty()) { |
| 91 | // Use the global input config | 91 | // Use the global input config |
| 92 | player = Settings::values.players.GetValue(true)[player_index]; | 92 | player = Settings::values.players.GetValue(true)[player_index]; |
| 93 | player.profile_name = ""; | ||
| 93 | return; | 94 | return; |
| 94 | } | 95 | } |
| 95 | } | 96 | } |
diff --git a/src/yuzu_cmd/sdl_config.cpp b/src/yuzu_cmd/sdl_config.cpp index 995114510..6e0f254b6 100644 --- a/src/yuzu_cmd/sdl_config.cpp +++ b/src/yuzu_cmd/sdl_config.cpp | |||
| @@ -103,6 +103,7 @@ void SdlConfig::ReadSdlPlayerValues(const std::size_t player_index) { | |||
| 103 | if (profile_name.empty()) { | 103 | if (profile_name.empty()) { |
| 104 | // Use the global input config | 104 | // Use the global input config |
| 105 | player = Settings::values.players.GetValue(true)[player_index]; | 105 | player = Settings::values.players.GetValue(true)[player_index]; |
| 106 | player.profile_name = ""; | ||
| 106 | return; | 107 | return; |
| 107 | } | 108 | } |
| 108 | } | 109 | } |