summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2018-10-06 04:54:01 +0200
committerGitHub <noreply@github.com>2018-10-06 04:54:01 +0200
commite6ee31a8e9f72add8ec61ae7e53f35b922bd90b2 (patch)
tree44b73707276d6a78dabc9b1d887d5bdd53cc5a53
parentMerge pull request #1438 from ReinUsesLisp/quads (diff)
parentui_settings: Place definition of the theme array within the cpp file (diff)
downloadyuzu-e6ee31a8e9f72add8ec61ae7e53f35b922bd90b2.tar
yuzu-e6ee31a8e9f72add8ec61ae7e53f35b922bd90b2.tar.gz
yuzu-e6ee31a8e9f72add8ec61ae7e53f35b922bd90b2.tar.bz2
yuzu-e6ee31a8e9f72add8ec61ae7e53f35b922bd90b2.tar.lz
yuzu-e6ee31a8e9f72add8ec61ae7e53f35b922bd90b2.tar.xz
yuzu-e6ee31a8e9f72add8ec61ae7e53f35b922bd90b2.tar.zst
yuzu-e6ee31a8e9f72add8ec61ae7e53f35b922bd90b2.zip
Diffstat (limited to '')
-rw-r--r--src/yuzu/configuration/configure_general.cpp2
-rw-r--r--src/yuzu/ui_settings.cpp8
-rw-r--r--src/yuzu/ui_settings.h5
3 files changed, 10 insertions, 5 deletions
diff --git a/src/yuzu/configuration/configure_general.cpp b/src/yuzu/configuration/configure_general.cpp
index 9292d9a42..f5db9e55b 100644
--- a/src/yuzu/configuration/configure_general.cpp
+++ b/src/yuzu/configuration/configure_general.cpp
@@ -13,7 +13,7 @@ ConfigureGeneral::ConfigureGeneral(QWidget* parent)
ui->setupUi(this);
- for (auto theme : UISettings::themes) {
+ for (const auto& theme : UISettings::themes) {
ui->theme_combobox->addItem(theme.first, theme.second);
}
diff --git a/src/yuzu/ui_settings.cpp b/src/yuzu/ui_settings.cpp
index 120b34990..a314493fc 100644
--- a/src/yuzu/ui_settings.cpp
+++ b/src/yuzu/ui_settings.cpp
@@ -6,5 +6,11 @@
namespace UISettings {
+const Themes themes{{
+ {"Default", "default"},
+ {"Dark", "qdarkstyle"},
+}};
+
Values values = {};
-}
+
+} // namespace UISettings
diff --git a/src/yuzu/ui_settings.h b/src/yuzu/ui_settings.h
index 051494bc5..2d679004f 100644
--- a/src/yuzu/ui_settings.h
+++ b/src/yuzu/ui_settings.h
@@ -15,9 +15,8 @@ namespace UISettings {
using ContextualShortcut = std::pair<QString, int>;
using Shortcut = std::pair<QString, ContextualShortcut>;
-static const std::array<std::pair<QString, QString>, 2> themes = {
- {std::make_pair(QString("Default"), QString("default")),
- std::make_pair(QString("Dark"), QString("qdarkstyle"))}};
+using Themes = std::array<std::pair<const char*, const char*>, 2>;
+extern const Themes themes;
struct Values {
QByteArray geometry;