From e7c8c7c1a49c05fcb075c362c67ac61f7dfdbed5 Mon Sep 17 00:00:00 2001 From: Dianne Hackborn Date: Wed, 7 Oct 2009 21:27:43 -0700 Subject: [PATCH] More fix #2163209: alarm clock rings but is hidden behind lock screen Another way we could miss the application's flags is because the system now force hides application windows behind the lock screen. So we need to use this new API to actually take those into account when looking for the top-most window that can specify for the lock screen to be removed or hidden. I have tested with pulling the device in and out of the desktop with all kinds of random speeds and ways and this -seems- to now cover everything. Keeping fingers crossed. Change-Id: Ice640eea6ee06ee27f069d60856fb394c7eeae51 --- .../android/internal/policy/impl/PhoneWindowManager.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/policy/com/android/internal/policy/impl/PhoneWindowManager.java b/policy/com/android/internal/policy/impl/PhoneWindowManager.java index 549fb87296475..4699638bb1045 100755 --- a/policy/com/android/internal/policy/impl/PhoneWindowManager.java +++ b/policy/com/android/internal/policy/impl/PhoneWindowManager.java @@ -1359,12 +1359,12 @@ public class PhoneWindowManager implements WindowManagerPolicy { win.computeFrameLw(pf, df, cf, vf); - if (win.isVisibleLw()) { + if (mTopFullscreenOpaqueWindowState == null && + win.isVisibleOrBehindKeyguardLw()) { if ((attrs.flags & FLAG_FORCE_NOT_FULLSCREEN) != 0) { mForceStatusBar = true; } - if (mTopFullscreenOpaqueWindowState == null - && attrs.type >= FIRST_APPLICATION_WINDOW + if (attrs.type >= FIRST_APPLICATION_WINDOW && attrs.type <= LAST_APPLICATION_WINDOW && win.fillsScreenLw(mW, mH, false, false)) { if (DEBUG_LAYOUT) Log.v(TAG, "Fullscreen window: " + win);