public void TestChange() { LanguageSetting languageSetting = new LanguageSetting(); SystemLanguage systemLanguage = Application.systemLanguage; languageSetting.ChangeLanguage(EnumLaungageSetting.EN); Assert.AreEqual(EnumLaungageSetting.EN, languageSetting.GetLanguage()); languageSetting.ChangeLanguage(EnumLaungageSetting.JP); Assert.AreEqual(EnumLaungageSetting.JP, languageSetting.GetLanguage()); }
public void TestDefault() { PlayerPrefs.SetInt(LanguageSetting.PREFS_KEY, LanguageSetting.NO_SETTING_LANGUAGE); LanguageSetting languageSetting = new LanguageSetting(); SystemLanguage systemLanguage = Application.systemLanguage; if (systemLanguage == SystemLanguage.Japanese) { Assert.AreEqual(EnumLaungageSetting.JP, languageSetting.GetLanguage()); } else { Assert.AreEqual(EnumLaungageSetting.EN, languageSetting.GetLanguage()); } }
protected string GetStyleSheet() { return(@"<link rel='stylesheet' type='text/css' href='" + Application["rootPath"] + "/StyleSheet/" + LanguageSetting.GetLanguage() + "_MASTERPAGE.css' />"); // @"<link rel='stylesheet' type='text/css' href='../StyleSheet/" + LanguageSetting.GetLanguage() + "_MASTERPAGE.css' />"; }
protected string __() { return(LanguageSetting.GetLanguage()); }