Only add system language on locale page

Bug: 229044305
Test: manual
Change-Id: Ia61aadbfe38969e54861dcbeb7ac4addc5f8d3be
This commit is contained in:
Calvin Pan
2022-04-13 06:10:20 +00:00
parent 729a22a2cc
commit 4c41490cb3

View File

@@ -175,8 +175,9 @@ public class LocalePickerWithRegion extends ListFragment implements SearchView.O
// Add current system language into suggestion list
for(LocaleStore.LocaleInfo localeInfo: LocaleStore.getSystemCurrentLocaleInfo()) {
if (appCurrentLocale == null ||
!localeInfo.getLocale().equals(appCurrentLocale.getLocale())) {
boolean isNotCurrentLocale = appCurrentLocale == null
|| !localeInfo.getLocale().equals(appCurrentLocale.getLocale());
if (!isForCountryMode && isNotCurrentLocale) {
mLocaleList.add(localeInfo);
}
}