Enable Danish in the code.

This commit is contained in:
Frederik "Freso" S. Olesen
2014-03-05 11:56:30 +01:00
parent 6901ba7513
commit 0b59cfa272
7 changed files with 13 additions and 0 deletions
+1
View File
@@ -81,6 +81,7 @@ const unsigned int boss_lang_french = boss::g_lang_french;
const unsigned int boss_lang_chinese = boss::g_lang_chinese;
const unsigned int boss_lang_polish = boss::g_lang_polish;
const unsigned int boss_lang_brazilian_portuguese = boss::g_lang_brazilian_portuguese;
const unsigned int boss_lang_danish = boss::g_lang_danish;
// BOSS cleanliness codes.
const unsigned int boss_needs_cleaning_no = 0;
+1
View File
@@ -177,6 +177,7 @@ BOSS_API extern const unsigned int boss_lang_french; ///< Tells the API to pref
BOSS_API extern const unsigned int boss_lang_chinese; ///< Tells the API to preferentially select Chinese messages.
BOSS_API extern const unsigned int boss_lang_polish; ///< Tells the API to preferentially select Polish messages.
BOSS_API extern const unsigned int boss_lang_brazilian_portuguese; ///< Tells the API to preferentially select Polish messages.
BOSS_API extern const unsigned int boss_lang_danish; ///< Tells the API to preferentially select Danish messages.
///@}
/*********************************//**
+1
View File
@@ -48,6 +48,7 @@ namespace boss {
const unsigned int g_lang_chinese = 5;
const unsigned int g_lang_polish = 6;
const unsigned int g_lang_brazilian_portuguese = 7;
const unsigned int g_lang_danish = 8;
//Version numbers.
const unsigned int g_version_major = 3;
+1
View File
@@ -49,6 +49,7 @@ namespace boss {
extern const unsigned int g_lang_chinese;
extern const unsigned int g_lang_polish;
extern const unsigned int g_lang_brazilian_portuguese;
extern const unsigned int g_lang_danish;
//Version numbers.
extern const unsigned int g_version_major;
+6
View File
@@ -251,6 +251,8 @@ namespace boss {
Construct(g_lang_polish);
else if (nameOrISOCode == Language(g_lang_brazilian_portuguese).Name() || nameOrISOCode == Language(g_lang_brazilian_portuguese).Locale())
Construct(g_lang_brazilian_portuguese);
else if (nameOrISOCode == Language(g_lang_danish).Name() || nameOrISOCode == Language(g_lang_danish).Locale())
Construct(g_lang_danish);
else
Construct(g_lang_any);
}
@@ -289,6 +291,10 @@ namespace boss {
_name = "Português do Brasil";
_locale = "pt_BR";
}
else if (_code == g_lang_danish) {
_name = "Dansk";
_locale = "da";
}
}
unsigned int Language::Code() const {
+1
View File
@@ -85,6 +85,7 @@ namespace boss {
vec.push_back(Language(g_lang_chinese).Name());
vec.push_back(Language(g_lang_polish).Name());
vec.push_back(Language(g_lang_brazilian_portuguese).Name());
vec.push_back(Language(g_lang_danish).Name());
return vec;
}
private:
+2
View File
@@ -254,6 +254,8 @@ bool BossGUI::OnInit() {
wxLang = wxLANGUAGE_POLISH;
else if (lang.Code() == boss::g_lang_brazilian_portuguese)
wxLang = wxLANGUAGE_PORTUGUESE_BRAZILIAN;
else if (lang.Code() == boss::g_lang_danish)
wxLang = wxLANGUAGE_DANISH;
}
//Boost.Locale initialisation: Specify location of language dictionaries.