Skip to content

Commit

Permalink
Add Japanese to language selection
Browse files Browse the repository at this point in the history
  • Loading branch information
Huntereb committed Mar 15, 2020
1 parent ae95a55 commit 82cb434
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 9 deletions.
21 changes: 13 additions & 8 deletions source/ui/optionsPage.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
namespace inst::ui {
extern MainApplication *mainApp;

std::vector<std::string> languageStrings = {"English", "Français", "Deutsch", "Italiano", "Русский"};
std::vector<std::string> languageStrings = {"English", "日本語", "Français", "Deutsch", "Italiano", "Русский"};

optionsPage::optionsPage() : Layout::Layout() {
this->SetBackgroundColor(COLOR("#670000FF"));
Expand Down Expand Up @@ -79,15 +79,17 @@ namespace inst::ui {
case 1:
case 12:
return languageStrings[0];
case 0:
return languageStrings[1];
case 2:
case 13:
return languageStrings[1];
case 3:
return languageStrings[2];
case 4:
case 3:
return languageStrings[3];
case 10:
case 4:
return languageStrings[4];
case 10:
return languageStrings[5];
default:
return "options.language.system_language"_lang;
}
Expand Down Expand Up @@ -202,15 +204,18 @@ namespace inst::ui {
inst::config::languageSetting = 1;
break;
case 1:
inst::config::languageSetting = 2;
inst::config::languageSetting = 0;
break;
case 2:
inst::config::languageSetting = 3;
inst::config::languageSetting = 2;
break;
case 3:
inst::config::languageSetting = 4;
inst::config::languageSetting = 3;
break;
case 4:
inst::config::languageSetting = 4;
break;
case 5:
inst::config::languageSetting = 10;
break;
default:
Expand Down
2 changes: 1 addition & 1 deletion source/util/lang.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace Language {
}
switch (langInt) {
case 0:
languagePath = "romfs:/lang/ja.json";
languagePath = "romfs:/lang/jp.json";
break;
case 2:
case 13:
Expand Down

0 comments on commit 82cb434

Please sign in to comment.