Mercurial > minori
comparison src/core/config.cc @ 223:84e0a3c4737a
library: implement menu bar buttons
I also went ahead and put the links from Taiga in so I don't have to
worry about it later...
author | Paper <mrpapersonic@gmail.com> |
---|---|
date | Mon, 08 Jan 2024 16:54:16 -0500 |
parents | 53211cb1e7f5 |
children | 7ca56c4ac0bc |
comparison
equal
deleted
inserted
replaced
222:b9f111d84d95 | 223:84e0a3c4737a |
---|---|
88 | 88 |
89 locale.SetActiveLocale(QLocale(Strings::ToQString(INI::GetIniValue<std::string>(ini, "General", "Locale", "en_US")))); | 89 locale.SetActiveLocale(QLocale(Strings::ToQString(INI::GetIniValue<std::string>(ini, "General", "Locale", "en_US")))); |
90 | 90 |
91 theme.SetTheme(Translate::ToTheme(INI::GetIniValue<std::string>(ini, "Appearance", "Theme", "Default"))); | 91 theme.SetTheme(Translate::ToTheme(INI::GetIniValue<std::string>(ini, "Appearance", "Theme", "Default"))); |
92 | 92 |
93 library.paths = Strings::Split(INI::GetIniValue<std::string>(ini, "Library", "Folders", ""), ";"); | |
94 | |
93 return 0; | 95 return 0; |
94 } | 96 } |
95 | 97 |
96 int Config::Save() const { | 98 int Config::Save() const { |
97 std::filesystem::path cfg_path = Filesystem::GetConfigPath(); | 99 std::filesystem::path cfg_path = Filesystem::GetConfigPath(); |
129 INI::SetIniValue(ini, "Recognition/Browsers", player.name, enabled); | 131 INI::SetIniValue(ini, "Recognition/Browsers", player.name, enabled); |
130 break; | 132 break; |
131 } | 133 } |
132 } | 134 } |
133 | 135 |
136 INI::SetIniValue(ini, "Library", "Folders", Strings::Implode(library.paths, ";")); | |
137 | |
134 file.write(ini); | 138 file.write(ini); |
135 | 139 |
136 return 0; | 140 return 0; |
137 } | 141 } |