Revert "Animate out bubbles in reverse of the way they animate in."
This reverts commit 90ff97ee31106f80b668d8aefda62dd671f4a21a.
Reason for revert: breaks some tests / behaviour; revert til fix
Change-Id: I40cee68dcd637d574bff4add692b3ef636e2e6f3
diff --git a/packages/SystemUI/src/com/android/systemui/bubbles/BubbleController.java b/packages/SystemUI/src/com/android/systemui/bubbles/BubbleController.java
index 494c1a2..7d9bb07 100644
--- a/packages/SystemUI/src/com/android/systemui/bubbles/BubbleController.java
+++ b/packages/SystemUI/src/com/android/systemui/bubbles/BubbleController.java
@@ -802,32 +802,16 @@
if (mStackView == null) {
return;
}
-
if (mStatusBarStateListener.getCurrentState() == SHADE && hasBubbles()) {
// Bubbles only appear in unlocked shade
mStackView.setVisibility(hasBubbles() ? VISIBLE : INVISIBLE);
- } else if (!hasBubbles() && mStackView.hasTransientBubbles()) {
- // If we only have transient bubbles, then wait until they're gone.
- mStackView.runActionAfterTransientViewAnimations(() -> {
- mStackView.setVisibility(INVISIBLE);
- updateBubblesShowing();
- });
- } else {
+ } else if (mStackView != null) {
mStackView.setVisibility(INVISIBLE);
}
- updateBubblesShowing();
- }
-
- /**
- * Updates the status bar window controller and the state change listener with whether bubbles
- * are currently showing.
- */
- public void updateBubblesShowing() {
+ // Let listeners know if bubble state changed.
boolean hadBubbles = mStatusBarWindowController.getBubblesShowing();
- boolean hasBubblesShowing =
- (hasBubbles() || mStackView.hasTransientBubbles())
- && mStackView.getVisibility() == VISIBLE;
+ boolean hasBubblesShowing = hasBubbles() && mStackView.getVisibility() == VISIBLE;
mStatusBarWindowController.setBubblesShowing(hasBubblesShowing);
if (mStateChangeListener != null && hadBubbles != hasBubblesShowing) {
mStateChangeListener.onHasBubblesChanged(hasBubblesShowing);