Show language names using system locale

pull/207/head
M66B 3 years ago
parent 160f59a7a8
commit dce0fda677

@ -244,8 +244,9 @@ public class FragmentOptionsMisc extends FragmentBase implements SharedPreferenc
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
Locale slocale = Resources.getSystem().getConfiguration().locale;
for (String tag : getResources().getAssets().getLocales())
languages.add(new Pair<>(tag, Locale.forLanguageTag(tag).getDisplayName()));
languages.add(new Pair<>(tag, Locale.forLanguageTag(tag).getDisplayName(slocale)));
Collections.sort(languages, new Comparator<Pair<String, String>>() {
@Override

Loading…
Cancel
Save