am 8e5bf181: am 0f7b0273: am 38586bff: Merge "Fix bug that prevented waking from dream" into mnc-dev
* commit '8e5bf1817e603e2c8343ee0a6f270409a2303d54': Fix bug that prevented waking from dream
This commit is contained in:
@@ -197,18 +197,25 @@ public class WindowAnimator {
|
|||||||
final WindowState winShowWhenLocked = (WindowState) mPolicy.getWinShowWhenLockedLw();
|
final WindowState winShowWhenLocked = (WindowState) mPolicy.getWinShowWhenLockedLw();
|
||||||
final AppWindowToken appShowWhenLocked = winShowWhenLocked == null ?
|
final AppWindowToken appShowWhenLocked = winShowWhenLocked == null ?
|
||||||
null : winShowWhenLocked.mAppToken;
|
null : winShowWhenLocked.mAppToken;
|
||||||
final boolean hideWhenLocked =
|
|
||||||
!(((win.mIsImWindow || imeTarget == win) && showImeOverKeyguard)
|
boolean allowWhenLocked = false;
|
||||||
|| (appShowWhenLocked != null && (appShowWhenLocked == win.mAppToken
|
// Show IME over the keyguard if the target allows it
|
||||||
// Show all SHOW_WHEN_LOCKED windows while they're animating
|
allowWhenLocked |= (win.mIsImWindow || imeTarget == win) && showImeOverKeyguard;
|
||||||
|| (win.mAttrs.flags & FLAG_SHOW_WHEN_LOCKED) != 0 && win.isAnimatingLw()
|
// Show SHOW_WHEN_LOCKED windows that turn on the screen
|
||||||
// Show error dialogs over apps that dismiss keyguard.
|
allowWhenLocked |= (win.mAttrs.flags & FLAG_SHOW_WHEN_LOCKED) != 0 && win.mTurnOnScreen;
|
||||||
|| (win.mAttrs.privateFlags & PRIVATE_FLAG_SYSTEM_ERROR) != 0)));
|
|
||||||
|
if (appShowWhenLocked != null) {
|
||||||
|
allowWhenLocked |= appShowWhenLocked == win.mAppToken
|
||||||
|
// Show all SHOW_WHEN_LOCKED windows while they're animating
|
||||||
|
|| (win.mAttrs.flags & FLAG_SHOW_WHEN_LOCKED) != 0 && win.isAnimatingLw()
|
||||||
|
// Show error dialogs over apps that dismiss keyguard.
|
||||||
|
|| (win.mAttrs.privateFlags & PRIVATE_FLAG_SYSTEM_ERROR) != 0;
|
||||||
|
}
|
||||||
|
|
||||||
// Only hide windows if the keyguard is active and not animating away.
|
// Only hide windows if the keyguard is active and not animating away.
|
||||||
boolean keyguardOn = mPolicy.isKeyguardShowingOrOccluded()
|
boolean keyguardOn = mPolicy.isKeyguardShowingOrOccluded()
|
||||||
&& mForceHiding != KEYGUARD_ANIMATING_OUT;
|
&& mForceHiding != KEYGUARD_ANIMATING_OUT;
|
||||||
return keyguardOn && hideWhenLocked && (win.getDisplayId() == Display.DEFAULT_DISPLAY);
|
return keyguardOn && !allowWhenLocked && (win.getDisplayId() == Display.DEFAULT_DISPLAY);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void updateWindowsLocked(final int displayId) {
|
private void updateWindowsLocked(final int displayId) {
|
||||||
|
|||||||
Reference in New Issue
Block a user