New languages

This commit is contained in:
stom79 2018-11-25 09:50:48 +01:00
parent 830396b27f
commit 3d73928197
2 changed files with 26 additions and 1 deletions

View File

@ -656,6 +656,26 @@ public class SettingsFragment extends Fragment {
editor.putString(Helper.SET_DEFAULT_LOCALE, Helper.localeToStringStorage(new Locale("el")));
editor.commit();
break;
case 13:
editor.putString(Helper.SET_DEFAULT_LOCALE, Helper.localeToStringStorage(new Locale("pt")));
editor.commit();
break;
case 14:
editor.putString(Helper.SET_DEFAULT_LOCALE, Helper.localeToStringStorage(new Locale("es")));
editor.commit();
break;
case 15:
editor.putString(Helper.SET_DEFAULT_LOCALE, Helper.localeToStringStorage(new Locale("pl")));
editor.commit();
break;
case 16:
editor.putString(Helper.SET_DEFAULT_LOCALE, Helper.localeToStringStorage(new Locale("sr")));
editor.commit();
break;
case 17:
editor.putString(Helper.SET_DEFAULT_LOCALE, Helper.localeToStringStorage(new Locale("uk")));
editor.commit();
break;
}
PackageManager packageManager = context.getPackageManager();
Intent intent = packageManager.getLaunchIntentForPackage(context.getPackageName());

View File

@ -2871,7 +2871,7 @@ public class Helper {
public static String[] getLocales(Context context){
String[] locale = new String[13];
String[] locale = new String[18];
locale[0] = context.getString(R.string.default_language);
locale[1] = Locale.ENGLISH.getDisplayLanguage();
locale[2] = Locale.FRANCE.getDisplayLanguage();
@ -2885,6 +2885,11 @@ public class Helper {
locale[10] = new Locale("nl").getDisplayLanguage();
locale[11] = new Locale("gl").getDisplayLanguage();
locale[12] = new Locale("el").getDisplayLanguage();
locale[13] = new Locale("pt").getDisplayLanguage();
locale[14] = new Locale("es").getDisplayLanguage();
locale[15] = new Locale("pl").getDisplayLanguage();
locale[16] = new Locale("sr").getDisplayLanguage();
locale[17] = new Locale("uk").getDisplayLanguage();
return locale;
}