Merge "FIx occlusion status mismatch issue when screen turns off and on quickly" into tm-qpr-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
eb902def7f
@@ -3324,8 +3324,8 @@ public class PhoneWindowManager implements WindowManagerPolicy {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onKeyguardOccludedChangedLw(boolean occluded) {
|
public void onKeyguardOccludedChangedLw(boolean occluded, boolean waitAppTransition) {
|
||||||
if (mKeyguardDelegate != null && mKeyguardDelegate.isShowing()) {
|
if (mKeyguardDelegate != null && waitAppTransition) {
|
||||||
mPendingKeyguardOccluded = occluded;
|
mPendingKeyguardOccluded = occluded;
|
||||||
mKeyguardOccludedChanged = true;
|
mKeyguardOccludedChanged = true;
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -166,9 +166,10 @@ public interface WindowManagerPolicy extends WindowManagerPolicyConstants {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Called when the Keyguard occluded state changed.
|
* Called when the Keyguard occluded state changed.
|
||||||
|
*
|
||||||
* @param occluded Whether Keyguard is currently occluded or not.
|
* @param occluded Whether Keyguard is currently occluded or not.
|
||||||
*/
|
*/
|
||||||
void onKeyguardOccludedChangedLw(boolean occluded);
|
void onKeyguardOccludedChangedLw(boolean occluded, boolean waitAppTransition);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Applies a keyguard occlusion change if one happened.
|
* Applies a keyguard occlusion change if one happened.
|
||||||
|
|||||||
@@ -403,8 +403,10 @@ class KeyguardController {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
mWindowManager.mPolicy.onKeyguardOccludedChangedLw(isDisplayOccluded(DEFAULT_DISPLAY));
|
final boolean waitAppTransition = isKeyguardLocked(displayId);
|
||||||
if (isKeyguardLocked(displayId)) {
|
mWindowManager.mPolicy.onKeyguardOccludedChangedLw(isDisplayOccluded(DEFAULT_DISPLAY),
|
||||||
|
waitAppTransition);
|
||||||
|
if (waitAppTransition) {
|
||||||
mService.deferWindowLayout();
|
mService.deferWindowLayout();
|
||||||
try {
|
try {
|
||||||
mRootWindowContainer.getDefaultDisplay()
|
mRootWindowContainer.getDefaultDisplay()
|
||||||
|
|||||||
@@ -222,7 +222,7 @@ class TestWindowManagerPolicy implements WindowManagerPolicy {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onKeyguardOccludedChangedLw(boolean occluded) {
|
public void onKeyguardOccludedChangedLw(boolean occluded, boolean waitAppTransition) {
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setSafeMode(boolean safeMode) {
|
public void setSafeMode(boolean safeMode) {
|
||||||
|
|||||||
Reference in New Issue
Block a user