Clear ActivityRecord#mDismissKeyguard flag after app launches.

This flag is used by the SysUI to dismiss an insecure keyguard
when an app is launched from an insecure lock screen. The flag
should only affect the app launch once, so needs to be cleared
once the flag is processed.

Bug: 234583880
Test: atest KeyguardTests#testDismissKeyguard_fromActivityOption_onlyOnce
Change-Id: Ia4179b40de7d45b2199b175a6dcc24016dfba091
This commit is contained in:
Issei Suzuki
2022-06-08 10:27:31 +00:00
parent 51d1c6ec66
commit 41cbf49af7
2 changed files with 1 additions and 1 deletions

View File

@@ -7399,7 +7399,6 @@ final class ActivityRecord extends WindowToken implements WindowManagerService.A
mTransit = TRANSIT_OLD_UNSET;
mTransitFlags = 0;
mNeedsAnimationBoundsLayer = false;
mDismissKeyguard = false;
setAppLayoutChanges(FINISH_LAYOUT_REDO_ANIM | FINISH_LAYOUT_REDO_WALLPAPER,
"ActivityRecord");

View File

@@ -627,6 +627,7 @@ class KeyguardController {
} else if (top.canShowWhenLocked()) {
mTopOccludesActivity = top;
}
top.mDismissKeyguard = false;
// Only the top activity may control occluded, as we can't occlude the Keyguard
// if the top app doesn't want to occlude it.