diff options
author | sxia <sxia@codeaurora.org> | 2020-04-22 18:00:39 +0800 |
---|---|---|
committer | shaohua xia <sxia@codeaurora.org> | 2020-04-24 06:43:57 +0000 |
commit | f8738b56eb4a7968b886bb26baf7a824eced97f0 (patch) | |
tree | a6f8f0d7bd94a6268f152d177412e64e2caf2487 /packages/SystemUI/src/com/android/keyguard/KeyguardSecurityModel.java | |
parent | d8271ae78b4e2b90dc5a0993967d865f02ff8b07 (diff) |
SystemUI: there is unexpected SIM PIN input dialog.
There is unexpected input dialog for SIM PIN.
Because the SystemUI set it sim state to ready after
verified the PIN lock, but the sim state in the
telephony is in PIN_REQUIRED.So the SystemUI will get
another security screen.
Do no act to PIN_REQUIRED after in READY state.
Change-Id: Ibaeec117cc67002e96d6125347f7694af59a7a0b
CRs-Fixed: 2669805
Diffstat (limited to 'packages/SystemUI/src/com/android/keyguard/KeyguardSecurityModel.java')
-rw-r--r-- | packages/SystemUI/src/com/android/keyguard/KeyguardSecurityModel.java | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/packages/SystemUI/src/com/android/keyguard/KeyguardSecurityModel.java b/packages/SystemUI/src/com/android/keyguard/KeyguardSecurityModel.java index 17abfae3c7e1..29910fea43ab 100644 --- a/packages/SystemUI/src/com/android/keyguard/KeyguardSecurityModel.java +++ b/packages/SystemUI/src/com/android/keyguard/KeyguardSecurityModel.java @@ -24,7 +24,7 @@ import android.telephony.TelephonyManager; import com.android.internal.widget.LockPatternUtils; import com.android.systemui.Dependency; - +import com.android.systemui.keyguard.KeyguardViewMediator; import javax.inject.Inject; import javax.inject.Singleton; @@ -65,13 +65,13 @@ public class KeyguardSecurityModel { public SecurityMode getSecurityMode(int userId) { KeyguardUpdateMonitor monitor = Dependency.get(KeyguardUpdateMonitor.class); - if (mIsPukScreenAvailable && SubscriptionManager.isValidSubscriptionId( - monitor.getNextSubIdForState(TelephonyManager.SIM_STATE_PUK_REQUIRED))) { + int subId = monitor.getUnlockedSubIdForState(TelephonyManager.SIM_STATE_PUK_REQUIRED); + if (mIsPukScreenAvailable && SubscriptionManager.isValidSubscriptionId(subId)){ return SecurityMode.SimPuk; } - if (SubscriptionManager.isValidSubscriptionId( - monitor.getNextSubIdForState(TelephonyManager.SIM_STATE_PIN_REQUIRED))) { + subId = monitor.getUnlockedSubIdForState(TelephonyManager.SIM_STATE_PIN_REQUIRED); + if (SubscriptionManager.isValidSubscriptionId((subId))){ return SecurityMode.SimPin; } |