File tree Expand file tree Collapse file tree 1 file changed +11
-5
lines changed
policy/src/com/android/internal/policy/impl Expand file tree Collapse file tree 1 file changed +11
-5
lines changed Original file line number Diff line number Diff line change @@ -532,11 +532,6 @@ public void onScreenTurnedOff() {
532532 if (DEBUG ) Log .d (TAG , "screen off" );
533533 mScreenOn = false ;
534534 mForgotPattern = false ;
535- if (mBiometricUnlock != null ) {
536- mSuppressBiometricUnlock =
537- mUpdateMonitor .getPhoneState () != TelephonyManager .CALL_STATE_IDLE
538- || mHasDialog ;
539- }
540535
541536 // Emulate activity life-cycle for both lock and unlock screen.
542537 if (mLockScreen != null ) {
@@ -991,6 +986,17 @@ private void initializeBiometricUnlockView(View view) {
991986 restartBiometricUnlock = mBiometricUnlock .stop ();
992987 }
993988
989+ // Prevents biometric unlock from coming up immediately after a phone call or if there
990+ // is a dialog on top of lockscreen. It is only updated if the screen is off because if the
991+ // screen is on it's either because of an orientation change, or when it first boots.
992+ // In both those cases, we don't want to override the current value of
993+ // mSuppressBiometricUnlock and instead want to use the previous value.
994+ if (!mScreenOn ) {
995+ mSuppressBiometricUnlock =
996+ mUpdateMonitor .getPhoneState () != TelephonyManager .CALL_STATE_IDLE
997+ || mHasDialog ;
998+ }
999+
9941000 // If the biometric unlock is not being used, we don't bother constructing it. Then we can
9951001 // simply check if it is null when deciding whether we should make calls to it.
9961002 mBiometricUnlock = null ;
You can’t perform that action at this time.
0 commit comments