libs/WindowManager/Shell/multivalentTests/src/com/android/wm/shell/bubbles/BubbleExpandedViewTest.kt
0 → 100644
+73
−0
Loading
Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more
When Flags.enableBubbleTaskViewListener() is enabled, the task ID is stored in BubbleTaskViewListener rather than directly in BubbleExpandedView's mTaskId field. This caused BubbleExpandedView.getTaskId() to return an uninitialized task ID, which broke onActivityRestartAttempt in the BubbleController. The issue occurs because onActivityRestartAttempt in BubbleController retrieves existing bubbles from BubbleData and calls Bubble.getTaskId() on each to find matches. Bubble.getTaskId() depends on BubbleExpandedView.getTaskId(), which was returning an uninitialized value when the flag was enabled. Bug: 272102927 Flag: com.android.wm.shell.enable_bubble_task_view_listener Test: atest WMShellRobolectricTests:BubbleExpandedViewTest Test: atest WMShellMultivalentTestsOnDevice:BubbleExpandedViewTest Change-Id: I0648b2865f9d82f33eac3b1e38b242c7405909f3