Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 955c97f8 authored by Roman Birg's avatar Roman Birg Committed by Gerrit Code Review
Browse files

SystemUI: improve keyguard with SIM PIN interactions



- Dismiss heads up popups when PIN is required, it would block input as
  the new PUK screen would pop up

- Also dismiss the PUK screen when the SIM is removed

Ticket: CYNGNOS-2843

Change-Id: Id42626faaa563215b128d7c830793d9908e5282d
Signed-off-by: default avatarRoman Birg <roman@cyngn.com>
parent d1bac5bc
Loading
Loading
Loading
Loading
+8 −9
Original line number Diff line number Diff line
@@ -484,8 +484,7 @@ public class KeyguardViewMediator extends SystemUI {
                    // only force lock screen in case of missing sim if user hasn't
                    // gone through setup wizard
                    synchronized (this) {
                        if (shouldWaitForProvisioning()) {
                            if (!mShowing) {
                        if (shouldWaitForProvisioning() && !mShowing) {
                            if (DEBUG_SIM_STATES) Log.d(TAG, "ICC_ABSENT isn't showing,"
                                    + " we need to show the keyguard since the "
                                    + "device isn't provisioned yet.");
@@ -494,11 +493,11 @@ public class KeyguardViewMediator extends SystemUI {
                            resetStateLocked();
                        }
                    }
                    }
                    break;
                case PIN_REQUIRED:
                case PUK_REQUIRED:
                    synchronized (this) {
                        mStatusBar.hideHeadsUp();
                        if (!mShowing) {
                            if (DEBUG_SIM_STATES) Log.d(TAG,
                                    "INTENT_VALUE_ICC_LOCKED and keygaurd isn't "
+6 −0
Original line number Diff line number Diff line
@@ -3721,6 +3721,12 @@ public class PhoneStatusBar extends BaseStatusBar implements DemoMode,
        }
    }

    public void hideHeadsUp() {
        if (mUseHeadsUp && mHeadsUpManager != null) {
            mHeadsUpManager.releaseAllImmediately();
        }
    }

    private void setControllerUsers() {
        if (mZenModeController != null) {
            mZenModeController.setUserId(mCurrentUserId);