Modify Taskbar code to accommodate bubble bar gesture to stash/unstash

* Bubble bar typically follows the behavior of taskbar - if taskbar
  is shown, the bubble bar is shown, if taskbar hides, bubble bar
  hides.
* The bubble bar has 3 states: stashed, collapsed (unstashed but
  the bubbles are not expanded), and expanded. When bubbles are
  expanded, this means WMShell is rendering the bubble
  expanded view. In this situation taskbar becomes collapsed.

Bug: 253318833
Test: manual, with other CLs, see go/bubble-bar-tests
Flag: WM_BUBBLE_BAR
Change-Id: Ic210c382e7482c259ae543a0dc083fe9305cbf5b
This commit is contained in:
Mady Mellor
2023-04-07 14:14:09 -07:00
parent 39e28c9190
commit 7344766886
10 changed files with 188 additions and 37 deletions
@@ -408,6 +408,14 @@ public class TaskbarLauncherStateController {
+ ", mLauncherState: " + mLauncherState
+ ", toAlignment: " + toAlignment);
}
mControllers.bubbleControllers.ifPresent(controllers -> {
// Show the bubble bar when on launcher home or in overview.
boolean onHome = isInLauncher && mLauncherState == LauncherState.NORMAL;
boolean onOverview = mLauncherState == LauncherState.OVERVIEW;
controllers.bubbleStashController.setBubblesShowingOnHome(onHome);
controllers.bubbleStashController.setBubblesShowingOnOverview(onOverview);
});
AnimatorSet animatorSet = new AnimatorSet();
if (hasAnyFlag(changedFlags, FLAG_LAUNCHER_IN_STATE_TRANSITION)) {
@@ -475,7 +483,7 @@ public class TaskbarLauncherStateController {
TaskbarStashController stashController =
mControllers.taskbarStashController;
stashController.updateAndAnimateTransientTaskbar(
/* stash */ true, /* duration */ 0);
/* stash */ true, /* duration */ 0, true /* bubblesShouldFollow */);
}
});
} else {