From 2dc47c1dd55818a0bd68847215adccfe39d6dd88 Mon Sep 17 00:00:00 2001 From: Jorim Jaggi Date: Fri, 5 May 2017 17:39:58 +0200 Subject: [PATCH] Exit transient mode as soon as status bar window is fullscreen When bouncer was popping up this caused us to call PWM.adjustSystemUiVisibility from SystemUI. Since the transient flag got cleared in that case we also hided the status bar, as we assumed we are still in transient mode. Instead, we exit transient mode as soon as the window is fullscreen, which is quite robust. This is not a perfect fix but given that the transient bar logic is so quirky that needs to be rewritten at some point this fix is good enough for now. Test: Open camera, swipe down to show transient bars, click on the Lock icon in the camera activity. Fixes: 36333950 Change-Id: I6939c26f283d7d791c22d5891b62a705f62c116f --- .../java/com/android/server/policy/PhoneWindowManager.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/services/core/java/com/android/server/policy/PhoneWindowManager.java b/services/core/java/com/android/server/policy/PhoneWindowManager.java index 4fb18d9e17c0f..472398c64e763 100644 --- a/services/core/java/com/android/server/policy/PhoneWindowManager.java +++ b/services/core/java/com/android/server/policy/PhoneWindowManager.java @@ -5427,7 +5427,8 @@ public class PhoneWindowManager implements WindowManagerPolicy { // Maintain fullscreen layout until incoming animation is complete. topIsFullscreen = mTopIsFullscreen && mStatusBar.isAnimatingLw(); // Transient status bar on the lockscreen is not allowed - if (mForceStatusBarFromKeyguard && mStatusBarController.isTransientShowing()) { + if ((mForceStatusBarFromKeyguard || statusBarExpanded) + && mStatusBarController.isTransientShowing()) { mStatusBarController.updateVisibilityLw(false /*transientAllowed*/, mLastSystemUiFlags, mLastSystemUiFlags); }