Add notification count to content description for badged apps
Bug: 70389249
Change-Id: If7f43941d501ba807adbb33d489da3944c012e94
diff --git a/src/com/android/launcher3/BubbleTextView.java b/src/com/android/launcher3/BubbleTextView.java
index 46d7227..dbdb2dc 100644
--- a/src/com/android/launcher3/BubbleTextView.java
+++ b/src/com/android/launcher3/BubbleTextView.java
@@ -560,6 +560,15 @@
invalidate();
}
}
+ if (itemInfo.contentDescription != null) {
+ if (hasBadge()) {
+ int count = mBadgeInfo.getNotificationCount();
+ setContentDescription(getContext().getResources().getQuantityString(
+ R.plurals.badged_app_label, count, itemInfo.contentDescription, count));
+ } else {
+ setContentDescription(itemInfo.contentDescription);
+ }
+ }
}
}