Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 499c5e60 authored by Josh Tsuji's avatar Josh Tsuji Committed by Automerger Merge Worker
Browse files

Merge "Force top UI if we're expanded, per Jorim's suggestion." into rvc-dev...

Merge "Force top UI if we're expanded, per Jorim's suggestion." into rvc-dev am: b20343ff am: d8424668 am: 6b750259 am: 3a950d70

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11959352

Change-Id: I1f1f411025dc3efcdafc2e530962f8cc33ac7814
parents aa62a351 3a950d70
Loading
Loading
Loading
Loading
+9 −0
Original line number Diff line number Diff line
@@ -207,6 +207,12 @@ public class BubbleController implements ConfigurationController.ConfigurationLi
    /** Whether or not the BubbleStackView has been added to the WindowManager. */
    private boolean mAddedToWindowManager = false;

    /**
     * Value from {@link NotificationShadeWindowController#getForceHasTopUi()} when we forced top UI
     * due to expansion. We'll restore this value when the stack collapses.
     */
    private boolean mHadTopUi = false;

    // Listens to user switch so bubbles can be saved and restored.
    private final NotificationLockscreenUserManager mNotifUserManager;

@@ -1292,6 +1298,7 @@ public class BubbleController implements ConfigurationController.ConfigurationLi
            // Collapsing? Do this first before remaining steps.
            if (update.expandedChanged && !update.expanded) {
                mStackView.setExpanded(false);
                mNotificationShadeWindowController.setForceHasTopUi(mHadTopUi);
            }

            // Do removals, if any.
@@ -1378,6 +1385,8 @@ public class BubbleController implements ConfigurationController.ConfigurationLi
            if (update.expandedChanged && update.expanded) {
                if (mStackView != null) {
                    mStackView.setExpanded(true);
                    mHadTopUi = mNotificationShadeWindowController.getForceHasTopUi();
                    mNotificationShadeWindowController.setForceHasTopUi(true);
                }
            }