mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-21 21:55:38 +00:00
Changed the default theme from slate-es-de to linear-es-de
This commit is contained in:
parent
5b4e284a2e
commit
f8d2086ef1
|
@ -166,12 +166,12 @@ void GuiMenu::openUIOptions()
|
|||
Scripting::fireEvent("theme-changed", theme->getSelected(),
|
||||
Settings::getInstance()->getString("Theme"));
|
||||
// Handle the situation where the previously selected theme has been deleted
|
||||
// using the theme downloader. In this case attempt to fall back to slate-es-de
|
||||
// using the theme downloader. In this case attempt to fall back to linear-es-de
|
||||
// and if this theme doesn't exist then select the first available one.
|
||||
auto themes = ThemeData::getThemes();
|
||||
if (themes.find(theme->getSelected()) == themes.end()) {
|
||||
if (themes.find("slate-es-de") != themes.end())
|
||||
Settings::getInstance()->setString("Theme", "slate-es-de");
|
||||
if (themes.find("linear-es-de") != themes.end())
|
||||
Settings::getInstance()->setString("Theme", "linear-es-de");
|
||||
else
|
||||
Settings::getInstance()->setString("Theme", themes.begin()->first);
|
||||
}
|
||||
|
|
|
@ -162,7 +162,7 @@ void Settings::setDefaults()
|
|||
mBoolMap["ScraperRegionFallback"] = {true, true};
|
||||
|
||||
// UI settings.
|
||||
mStringMap["Theme"] = {"slate-es-de", "slate-es-de"};
|
||||
mStringMap["Theme"] = {"linear-es-de", "linear-es-de"};
|
||||
mStringMap["ThemeVariant"] = {"", ""};
|
||||
mStringMap["ThemeColorScheme"] = {"", ""};
|
||||
mStringMap["ThemeFontSize"] = {"", ""};
|
||||
|
|
|
@ -820,11 +820,11 @@ const std::string ThemeData::getSystemThemeFile(const std::string& system)
|
|||
std::map<std::string, Theme, StringComparator>::const_iterator theme {
|
||||
sThemes.find(Settings::getInstance()->getString("Theme"))};
|
||||
if (theme == sThemes.cend()) {
|
||||
// Currently configured theme is missing, attempt to load the default theme slate-es-de
|
||||
// Currently configured theme is missing, attempt to load the default theme linear-es-de
|
||||
// instead, and if that's also missing then pick the first available one.
|
||||
bool defaultSetFound {true};
|
||||
|
||||
theme = sThemes.find("slate-es-de");
|
||||
theme = sThemes.find("linear-es-de");
|
||||
|
||||
if (theme == sThemes.cend()) {
|
||||
theme = sThemes.cbegin();
|
||||
|
|
Loading…
Reference in a new issue