mirror of https://github.com/axmolengine/axmol.git
add russian language support
This commit is contained in:
parent
cf3cecc108
commit
240aa4c077
|
@ -62,6 +62,7 @@ typedef enum LanguageType
|
||||||
kLanguageItalian,
|
kLanguageItalian,
|
||||||
kLanguageGerman,
|
kLanguageGerman,
|
||||||
kLanguageSpanish,
|
kLanguageSpanish,
|
||||||
|
kLanguageRussian
|
||||||
} ccLanguageType;
|
} ccLanguageType;
|
||||||
|
|
||||||
NS_CC_END;
|
NS_CC_END;
|
||||||
|
|
|
@ -58,36 +58,33 @@ CCApplication& CCApplication::sharedApplication()
|
||||||
ccLanguageType CCApplication::getCurrentLanguage()
|
ccLanguageType CCApplication::getCurrentLanguage()
|
||||||
{
|
{
|
||||||
ccLanguageType ret = kLanguageEnglish;
|
ccLanguageType ret = kLanguageEnglish;
|
||||||
do
|
result r = E_SUCCESS;
|
||||||
|
String value;
|
||||||
|
r = SettingInfo::GetValue(L"Language", value);
|
||||||
|
if (value.Equals("ZHO", false))
|
||||||
{
|
{
|
||||||
result r = E_SUCCESS;
|
ret = kLanguageChinese;
|
||||||
String value;
|
}
|
||||||
r = SettingInfo::GetValue(L"Language", value);
|
else if (value.Equals("FRA", false))
|
||||||
if (value.Equals("ZHO", false))
|
{
|
||||||
{
|
ret = kLanguageFrench;
|
||||||
ret = kLanguageChinese;
|
}
|
||||||
}
|
else if (value.Equals("ITA", false))
|
||||||
else if (value.Equals("FRA", false))
|
{
|
||||||
{
|
ret = kLanguageItalian;
|
||||||
ret = kLanguageFrench;
|
}
|
||||||
}
|
else if (value.Equals("DEU", false))
|
||||||
else if (value.Equals("ITA", false))
|
{
|
||||||
{
|
ret = kLanguageGerman;
|
||||||
ret = kLanguageItalian;
|
}
|
||||||
}
|
else if (value.Equals("SPA", false))
|
||||||
else if (value.Equals("DEU", false))
|
{
|
||||||
{
|
ret = kLanguageSpanish;
|
||||||
ret = kLanguageGerman;
|
}
|
||||||
}
|
else if (value.Equals("RUS", false))
|
||||||
else if (value.Equals("SPA", false))
|
{
|
||||||
{
|
ret = kLanguageRussian;
|
||||||
ret = kLanguageSpanish;
|
}
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
ret = kLanguageEnglish;
|
|
||||||
}
|
|
||||||
} while (0);
|
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue