Fixing icon label not updated during bulk load

The label was being updated to default in Loader cursor
which prevented eventual final update of the label

Bug: 220645719
Test: Verified on device
Change-Id: I2559804eb885663387bd1f5afe9e3337130a9fe3
This commit is contained in:
Sunny Goyal
2022-07-21 15:43:00 -07:00
parent 026ddc4460
commit 412f0d26fa

View File

@@ -291,12 +291,16 @@ public class LoaderCursor extends CursorWrapper {
// from the db
if (TextUtils.isEmpty(info.title)) {
info.title = getTitle();
}
if (loadIcon) {
info.title = getTitle();
// fall back to the class name of the activity
if (info.title == null) {
info.title = componentName.getClassName();
// fall back to the class name of the activity
if (info.title == null) {
info.title = componentName.getClassName();
}
} else {
info.title = "";
}
}
info.contentDescription = mPM.getUserBadgedLabel(info.title, info.user);