Refactor how app pair icons draw

This changes (and cleans up) the way app pair icons are composed. Previously, the background and 2 icons were drawn individually and separately onto the canvas. Now, they are composed into a combined drawable first. This also allows the full icon drawable to be requested by external functions (which will be needed for display app pairs in folder previews).

Bug: 315731527
Flag: ACONFIG com.android.wm.shell.enable_app_pairs TRUNKFOOD
Test: Visually confirmed that app pairs loooks the same in all scenarios: rotation, disabled, themed, taskbar, pinned taskbar. Screenshot test to follow.
Change-Id: I7242e0c525ef578a54a06fb9137fcfc42c6f0e86
This commit is contained in:
Jeremy Sim committed 2024-03-25 16:43:40 -07:00
1 parent 3a7432d782
commit b37faec287
9 files changed
+427 -317

No files matched your search

@@ -354,7 +354,8 @@ public class TaskbarView extends FrameLayout implements FolderIcon.FolderIconPar
break;
case ITEM_TYPE_APP_PAIR:
hotseatView = AppPairIcon.inflateIcon(
expectedLayoutResId, mActivityContext, this, folderInfo);
expectedLayoutResId, mActivityContext, this, folderInfo,
BubbleTextView.DISPLAY_TASKBAR);
((AppPairIcon) hotseatView).setTextVisible(false);
break;
default: