mirror of
https://github.com/Lime3DS/Lime3DS
synced 2024-12-25 00:23:04 -06:00
citra-qt: add new uisetting->theme
This commit is contained in:
parent
6d436d7a52
commit
bbeb9f1dbb
2 changed files with 9 additions and 0 deletions
|
@ -134,6 +134,7 @@ void Config::ReadValues() {
|
|||
qt_config->endGroup();
|
||||
|
||||
qt_config->beginGroup("UI");
|
||||
UISettings::values.theme = qt_config->value("theme", UISettings::themes[0].second).toString();
|
||||
|
||||
qt_config->beginGroup("UILayout");
|
||||
UISettings::values.geometry = qt_config->value("geometry").toByteArray();
|
||||
|
@ -269,6 +270,7 @@ void Config::SaveValues() {
|
|||
qt_config->endGroup();
|
||||
|
||||
qt_config->beginGroup("UI");
|
||||
qt_config->setValue("theme", UISettings::values.theme);
|
||||
|
||||
qt_config->beginGroup("UILayout");
|
||||
qt_config->setValue("geometry", UISettings::values.geometry);
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include <array>
|
||||
#include <vector>
|
||||
#include <QByteArray>
|
||||
#include <QString>
|
||||
|
@ -14,6 +15,10 @@ 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"))}};
|
||||
|
||||
struct Values {
|
||||
QByteArray geometry;
|
||||
QByteArray state;
|
||||
|
@ -39,6 +44,8 @@ struct Values {
|
|||
bool gamedir_deepscan;
|
||||
QStringList recent_files;
|
||||
|
||||
QString theme;
|
||||
|
||||
// Shortcut name <Shortcut, context>
|
||||
std::vector<Shortcut> shortcuts;
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue