diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelViewController.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelViewController.java index 366cd07edaaee..960678fb98470 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelViewController.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelViewController.java @@ -3038,10 +3038,11 @@ public class NotificationPanelViewController extends PanelViewController { private void updatePanelExpanded() { boolean isExpanded = !isFullyCollapsed() || mExpectingSynthesizedDown; if (mPanelExpanded != isExpanded) { + mPanelExpanded = isExpanded; + mHeadsUpManager.setIsPanelExpanded(isExpanded); mStatusBarTouchableRegionManager.setPanelExpanded(isExpanded); mCentralSurfaces.setPanelExpanded(isExpanded); - mPanelExpanded = isExpanded; if (!isExpanded && mQs != null && mQs.isCustomizing()) { mQs.closeCustomizer(); @@ -3049,6 +3050,10 @@ public class NotificationPanelViewController extends PanelViewController { } } + boolean isPanelExpanded() { + return mPanelExpanded; + } + private int calculatePanelHeightShade() { final int maxHeight = mNotificationStackScrollLayoutController.getHeight(); if (mBarState == KEYGUARD) { diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/UnlockedScreenOffAnimationController.kt b/packages/SystemUI/src/com/android/systemui/statusbar/phone/UnlockedScreenOffAnimationController.kt index b11751554db37..d058b75fd1b11 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/UnlockedScreenOffAnimationController.kt +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/UnlockedScreenOffAnimationController.kt @@ -313,7 +313,7 @@ class UnlockedScreenOffAnimationController @Inject constructor( // already expanded and showing notifications/QS, the animation looks really messy. For now, // disable it if the notification panel is expanded. if ((!this::mCentralSurfaces.isInitialized || - mCentralSurfaces.notificationPanelViewController.isExpanded) && + mCentralSurfaces.notificationPanelViewController.isPanelExpanded) && // Status bar might be expanded because we have started // playing the animation already !isAnimationPlaying()