Fix #2163209: alarm clock rings but is hidden behind lock screen

The lock screen's flag to force the status bar on was sometimes
interfering with the flag of the alarm behind to hide the lock screen.

Change-Id: I91368c56d09d35b03db548530aa1eb59197206bd
diff --git a/policy/com/android/internal/policy/impl/PhoneWindowManager.java b/policy/com/android/internal/policy/impl/PhoneWindowManager.java
index 12821e9..cec41f7 100755
--- a/policy/com/android/internal/policy/impl/PhoneWindowManager.java
+++ b/policy/com/android/internal/policy/impl/PhoneWindowManager.java
@@ -1366,7 +1366,8 @@
         if (win.isVisibleLw()) {
             if ((attrs.flags & FLAG_FORCE_NOT_FULLSCREEN) != 0) {
                 mForceStatusBar = true;
-            } else if (mTopFullscreenOpaqueWindowState == null
+            } 
+            if (mTopFullscreenOpaqueWindowState == null
                     && attrs.type >= FIRST_APPLICATION_WINDOW
                     && attrs.type <= LAST_APPLICATION_WINDOW
                     && win.fillsScreenLw(mW, mH, false, false)) {
@@ -1407,8 +1408,8 @@
         int changes = 0;
         boolean hiding = false;
         if (mStatusBar != null) {
-            //Log.i(TAG, "force=" + mForceStatusBar
-            //        + " top=" + mTopFullscreenOpaqueWindowState);
+            if (localLOGV) Log.i(TAG, "force=" + mForceStatusBar
+                    + " top=" + mTopFullscreenOpaqueWindowState);
             if (mForceStatusBar) {
                 if (DEBUG_LAYOUT) Log.v(TAG, "Showing status bar");
                 if (mStatusBar.showLw(true)) changes |= FINISH_LAYOUT_REDO_LAYOUT;
@@ -1435,7 +1436,7 @@
         if (mKeyguard != null) {
             if (localLOGV) Log.v(TAG, "finishLayoutLw::mHideKeyguard="+mHideLockScreen);
             if (mDismissKeyguard && !mKeyguardMediator.isSecure()) {
-                if (mKeyguard.hideLw(true)) {
+                if (mKeyguard.hideLw(false)) {
                     changes |= FINISH_LAYOUT_REDO_LAYOUT
                             | FINISH_LAYOUT_REDO_CONFIG
                             | FINISH_LAYOUT_REDO_WALLPAPER;
@@ -1448,7 +1449,7 @@
                     });
                 }
             } else if (mHideLockScreen) {
-                if (mKeyguard.hideLw(true)) {
+                if (mKeyguard.hideLw(false)) {
                     changes |= FINISH_LAYOUT_REDO_LAYOUT
                             | FINISH_LAYOUT_REDO_CONFIG
                             | FINISH_LAYOUT_REDO_WALLPAPER;