Fix using incorrect view in app language selection

Bug: 233175025
Test: By manual
Change-Id: Idd5b277cdfb737acf9262ff5efbeca93afaa100f
This commit is contained in:
Calvin Pan
2022-05-25 02:47:23 +00:00
parent 49c4f9e051
commit 5f8fa45e80

View File

@@ -261,7 +261,7 @@ public class SuggestedLocaleAdapter extends BaseAdapter implements Filterable {
updatedView = mInflater.inflate(
R.layout.app_language_picker_current_locale_item,
parent, false);
addStateDescriptionIntoCurrentLocaleItem(convertView);
addStateDescriptionIntoCurrentLocaleItem(updatedView);
}
} else {
shouldReuseView = convertView instanceof TextView
@@ -278,7 +278,7 @@ public class SuggestedLocaleAdapter extends BaseAdapter implements Filterable {
if (!shouldReuseView) {
updatedView = mInflater.inflate(
R.layout.app_language_picker_current_locale_item, parent, false);
addStateDescriptionIntoCurrentLocaleItem(convertView);
addStateDescriptionIntoCurrentLocaleItem(updatedView);
}
break;
default: