Follow-up for I8cbf1bfbebc917b03f528f040bb019d193228bbb
Actually update when force is true. Test: Check occluded Keyguard. Bug: 36407040 Change-Id: I8efdbca0bececf5075da71b2efe246fda37ef610
This commit is contained in:
@@ -5475,9 +5475,10 @@ public class PhoneWindowManager implements WindowManagerPolicy {
|
||||
*/
|
||||
private boolean setKeyguardOccludedLw(boolean isOccluded, boolean force) {
|
||||
if (DEBUG_KEYGUARD) Slog.d(TAG, "setKeyguardOccluded occluded=" + isOccluded);
|
||||
boolean wasOccluded = mKeyguardOccluded;
|
||||
boolean showing = mKeyguardDelegate.isShowing();
|
||||
if (wasOccluded && !isOccluded && showing) {
|
||||
final boolean wasOccluded = mKeyguardOccluded;
|
||||
final boolean showing = mKeyguardDelegate.isShowing();
|
||||
final boolean changed = wasOccluded != isOccluded || force;
|
||||
if (!isOccluded && changed && showing) {
|
||||
mKeyguardOccluded = false;
|
||||
mKeyguardDelegate.setOccluded(false, true /* animate */);
|
||||
if (mStatusBar != null) {
|
||||
@@ -5487,7 +5488,7 @@ public class PhoneWindowManager implements WindowManagerPolicy {
|
||||
}
|
||||
}
|
||||
return true;
|
||||
} else if (!wasOccluded && isOccluded && showing) {
|
||||
} else if (isOccluded && changed && showing) {
|
||||
mKeyguardOccluded = true;
|
||||
mKeyguardDelegate.setOccluded(true, false /* animate */);
|
||||
if (mStatusBar != null) {
|
||||
@@ -5495,7 +5496,7 @@ public class PhoneWindowManager implements WindowManagerPolicy {
|
||||
mStatusBar.getAttrs().flags &= ~FLAG_SHOW_WALLPAPER;
|
||||
}
|
||||
return true;
|
||||
} else if (wasOccluded != isOccluded) {
|
||||
} else if (changed) {
|
||||
mKeyguardOccluded = isOccluded;
|
||||
mKeyguardDelegate.setOccluded(isOccluded, false /* animate */);
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user