summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorv1993 <v19930312@gmail.com>2022-01-21 18:51:19 +0100
committerv1993 <v19930312@gmail.com>2022-01-21 18:57:00 +0100
commitd63d8bf7f94e28fc03a9cc888ca1dafb57960bb5 (patch)
treed779b057ef565864a2f19787c4bce5ff7b689080 /src
parentMerge pull request #7695 from Morph1984/is-pow2 (diff)
downloadyuzu-d63d8bf7f94e28fc03a9cc888ca1dafb57960bb5.tar
yuzu-d63d8bf7f94e28fc03a9cc888ca1dafb57960bb5.tar.gz
yuzu-d63d8bf7f94e28fc03a9cc888ca1dafb57960bb5.tar.bz2
yuzu-d63d8bf7f94e28fc03a9cc888ca1dafb57960bb5.tar.lz
yuzu-d63d8bf7f94e28fc03a9cc888ca1dafb57960bb5.tar.xz
yuzu-d63d8bf7f94e28fc03a9cc888ca1dafb57960bb5.tar.zst
yuzu-d63d8bf7f94e28fc03a9cc888ca1dafb57960bb5.zip
Diffstat (limited to '')
-rw-r--r--src/yuzu/configuration/config.cpp9
-rw-r--r--src/yuzu/configuration/config.h8
2 files changed, 11 insertions, 6 deletions
diff --git a/src/yuzu/configuration/config.cpp b/src/yuzu/configuration/config.cpp
index 33d50667a..8c370ff91 100644
--- a/src/yuzu/configuration/config.cpp
+++ b/src/yuzu/configuration/config.cpp
@@ -745,8 +745,7 @@ void Config::ReadUIValues() {
UISettings::values.theme =
ReadSetting(
QStringLiteral("theme"),
- QString::fromUtf8(
- UISettings::themes[static_cast<size_t>(UISettings::Theme::DarkColorful)].second))
+ QString::fromUtf8(UISettings::themes[static_cast<size_t>(default_theme)].second))
.toString();
ReadBasicSetting(UISettings::values.enable_discord_presence);
ReadBasicSetting(UISettings::values.select_user_on_boot);
@@ -1273,10 +1272,8 @@ void Config::SaveSystemValues() {
void Config::SaveUIValues() {
qt_config->beginGroup(QStringLiteral("UI"));
- WriteSetting(
- QStringLiteral("theme"), UISettings::values.theme,
- QString::fromUtf8(
- UISettings::themes[static_cast<size_t>(UISettings::Theme::DarkColorful)].second));
+ WriteSetting(QStringLiteral("theme"), UISettings::values.theme,
+ QString::fromUtf8(UISettings::themes[static_cast<size_t>(default_theme)].second));
WriteBasicSetting(UISettings::values.enable_discord_presence);
WriteBasicSetting(UISettings::values.select_user_on_boot);
diff --git a/src/yuzu/configuration/config.h b/src/yuzu/configuration/config.h
index d673c1cdc..8f4576def 100644
--- a/src/yuzu/configuration/config.h
+++ b/src/yuzu/configuration/config.h
@@ -48,6 +48,14 @@ public:
static const std::array<int, Settings::NativeKeyboard::NumKeyboardMods> default_keyboard_mods;
static const std::array<UISettings::Shortcut, 21> default_hotkeys;
+ static constexpr UISettings::Theme default_theme{
+#ifdef _WIN32
+ UISettings::Theme::DarkColorful
+#else
+ UISettings::Theme::DefaultColorful
+#endif
+ };
+
private:
void Initialize(const std::string& config_name);