summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Josh Tsuji <tsuji@google.com> 2023-01-18 16:42:12 -0500
committer Josh Tsuji <tsuji@google.com> 2023-01-19 10:26:49 -0500
commit09114c3e6e32d671fba5fa4ed8d2f21b5749754d (patch)
tree8aba015ec82090a61ce0db4d3484e76200918637
parent76c74ee9f255c89a7a028e8781aaab8897dbe79e (diff)
Fix issues with unlocking during a swipe on the lockscreen.
This could cause keyguard to remain visible if a biometric auth event arrived while swiping on the lockscreen. Fixes: 265661878 Test: while a bouncer swipe is in progress, finger/face auth Test: while swiping away an unlocked lockscreen, fingerprint auth Change-Id: Ia06f48f092414360c3c9d3cb16cb8fb42591f5b8
-rw-r--r--packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java4
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/phone/CentralSurfacesImpl.java2
2 files changed, 6 insertions, 0 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java b/packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java
index fe84ac5a32bc..2403d79db854 100644
--- a/packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java
+++ b/packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java
@@ -2287,6 +2287,10 @@ public class KeyguardViewMediator implements CoreStartable, Dumpable,
}
if (!mKeyguardDonePending && mHideAnimationRun && !mHideAnimationRunning) {
handleKeyguardDone();
+ } else if (mSurfaceBehindRemoteAnimationRunning) {
+ // We're already running the keyguard exit animation, likely due to an in-progress swipe
+ // to unlock.
+ exitKeyguardAndFinishSurfaceBehindRemoteAnimation(false /* cancelled */);
} else if (!mHideAnimationRun) {
if (DEBUG) Log.d(TAG, "tryKeyguardDone: starting pre-hide animation");
mHideAnimationRun = true;
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/CentralSurfacesImpl.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/CentralSurfacesImpl.java
index 8110b4747b63..adf7cc0731fa 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/CentralSurfacesImpl.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/CentralSurfacesImpl.java
@@ -1414,6 +1414,7 @@ public class CentralSurfacesImpl implements CoreStartable, CentralSurfaces {
// Things that mean we're not swiping to dismiss the keyguard, and should ignore this
// expansion:
// - Keyguard isn't even visible.
+ // - We're swiping on the bouncer, not the lockscreen.
// - Keyguard is occluded. Expansion changes here are the shade being expanded over the
// occluding activity.
// - Keyguard is visible, but can't be dismissed (swiping up will show PIN/password prompt).
@@ -1423,6 +1424,7 @@ public class CentralSurfacesImpl implements CoreStartable, CentralSurfaces {
// - QS is expanded and we're swiping - swiping up now will hide QS, not dismiss the
// keyguard.
if (!isKeyguardShowing()
+ || mStatusBarKeyguardViewManager.primaryBouncerIsOrWillBeShowing()
|| isOccluded()
|| !mKeyguardStateController.canDismissLockScreen()
|| mKeyguardViewMediator.isAnySimPinSecure()