feat(i18n): add ui localization (#2279)
Co-authored-by: TheElixZammuto <6505622+TheElixZammuto@users.noreply.github.com>
This commit is contained in:
parent
8316f44e10
commit
87774333f3
29 changed files with 4446 additions and 719 deletions
|
|
@ -441,6 +441,7 @@ namespace config {
|
|||
};
|
||||
|
||||
sunshine_t sunshine {
|
||||
"en", // locale
|
||||
2, // min_log_level
|
||||
0, // flags
|
||||
{}, // User file
|
||||
|
|
@ -1101,6 +1102,19 @@ namespace config {
|
|||
config::sunshine.flags[config::flag::UPNP].flip();
|
||||
}
|
||||
|
||||
string_restricted_f(vars, "locale", config::sunshine.locale, {
|
||||
"de"sv, // German
|
||||
"en"sv, // English
|
||||
"en-GB"sv, // English (UK)
|
||||
"en-US"sv, // English (US)
|
||||
"es"sv, // Spanish
|
||||
"fr"sv, // French
|
||||
"it"sv, // Italian
|
||||
"ru"sv, // Russian
|
||||
"sv"sv, // Swedish
|
||||
"zh"sv, // Chinese
|
||||
});
|
||||
|
||||
std::string log_level_string;
|
||||
string_f(vars, "min_log_level", log_level_string);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue