diff options
| author | 2024-05-24 14:41:32 +0000 | |
|---|---|---|
| committer | 2024-05-24 15:00:04 +0000 | |
| commit | ff1746c1f67f28a0366dea842f76974b7bdd70e4 (patch) | |
| tree | 1e6bd38e5d3f6696317476b29ba62a7e2f41d684 | |
| parent | 9cfe42549796114035a59976198340bc64c3dad0 (diff) | |
Set accessibility string for profile badge
Set string for talkback to describe profile
badge in the notification header.
Bug: 329375307
Test: checked talkback announcement for installation
notificaiton while installing apps for work and
private profiles
Change-Id: I3789150d2a889e7db201a85fd5697122bc1e8c44
| -rw-r--r-- | core/java/android/app/Notification.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/core/java/android/app/Notification.java b/core/java/android/app/Notification.java index dfae48b82909..367a3f74e576 100644 --- a/core/java/android/app/Notification.java +++ b/core/java/android/app/Notification.java @@ -5637,6 +5637,10 @@ public class Notification implements Parcelable contentView.setDrawableTint(R.id.profile_badge, false, getPrimaryTextColor(p), PorterDuff.Mode.SRC_ATOP); } + contentView.setContentDescription( + R.id.profile_badge, + mContext.getSystemService(UserManager.class) + .getProfileAccessibilityString(mContext.getUserId())); } } |