Fix bubble bar state after rotation on foldable
Currently when the views get updated for a mode change, it doesn't take into account the expanded state. This change ensures that if bubbles was expanded prior to a mode change, the expanded state gets applied to the layer view & that the expanded and selected state is sent over to launcher in the initial bubble bar state. The real root cause of this is that when a foldable is rotated, we're getting an unregister and then a register call for our bubble state listener from launcher, which causes a mode change. It would be good to check why that's happening because it seems incorrect, however, we shouldn't rely on launcher's correctness / should ensure the current state is applied which is what this CL does. Flag: com.android.wm.shell.bubble_bar Test: atest BubbleDataTest BubblesTest Test: manual - enable bubble bar on a foldable - expand bubbles, rotate device => observe that bubbles are expanded still => collapse bubbles and check that swipe to home and overview works fine Bug: 324443226 Change-Id: I12ec9755cc1d5de9d03ca2074eaac16a6bb1efa8
Showing
- libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleController.java 6 additions, 0 deletions...ll/src/com/android/wm/shell/bubbles/BubbleController.java
- libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleData.java 5 additions, 1 deletion...er/Shell/src/com/android/wm/shell/bubbles/BubbleData.java
- libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/bubbles/BubbleDataTest.java 19 additions, 0 deletions...test/src/com/android/wm/shell/bubbles/BubbleDataTest.java
- packages/SystemUI/tests/src/com/android/systemui/wmshell/BubblesTest.java 28 additions, 0 deletions...I/tests/src/com/android/systemui/wmshell/BubblesTest.java
Loading
Please register or sign in to comment