Add a contentDescription to splitscreen's first staged task

Currently, when we stage the first app in a split, the floatingTaskView has no contentDescription and is announced by screen readers as "unlabeled".

This CL allows FloatingTaskView to copy a contentDescription from the underlying task or ItemInfo when it is created.

Also changes SplitConfigurationOptions#itemInfo to a private field with a public getter for mockito compatibility.

Fixes: 319783133
Test: Confirmed with TalkBack on Overview, contextual and Intent splits
Flag: EXEMPT bugfix
Change-Id: Ia5a95e403bfe8623e17d2ceac9073ef15c7bb476
This commit is contained in:
Jeremy Sim committed 2024-08-20 03:19:58 +00:00
1 parent 9df623644a
commit 2e59268f3b
6 files changed
+24 -9

No files matched your search

@@ -211,7 +211,7 @@ public final class SplitConfigurationOptions {
private Drawable drawable;
public final Intent intent;
public final SplitPositionOption position;
public final ItemInfo itemInfo;
private ItemInfo itemInfo;
public final StatsLogManager.EventEnum splitEvent;
/** Represents the taskId of the first app to start in split screen */
public int alreadyRunningTaskId = INVALID_TASK_ID;
@@ -239,5 +239,9 @@ public final class SplitConfigurationOptions {
public View getView() {
return view;
}
public ItemInfo getItemInfo() {
return itemInfo;
}
}
}