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

Commit 90d6c568 authored by Adrian Roos's avatar Adrian Roos
Browse files

Don't show RedactionInterstitial when changing password

Only show when going from an insecure to secure lock.

Bug: 18467783
Change-Id: Ia73682d45b1dcd9ad61a00abeac099a94256e3b7
parent 239d185a
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -425,6 +425,7 @@ public class ChooseLockPassword extends SettingsActivity {
                if (mFirstPin.equals(pin)) {
                    final boolean isFallback = getActivity().getIntent().getBooleanExtra(
                            LockPatternUtils.LOCKSCREEN_BIOMETRIC_WEAK_FALLBACK, false);
                    boolean wasSecureBefore = mLockPatternUtils.isSecure();
                    mLockPatternUtils.clearLock(isFallback);
                    final boolean required = getActivity().getIntent().getBooleanExtra(
                            EncryptionInterstitial.EXTRA_REQUIRE_PASSWORD, true);
@@ -433,7 +434,9 @@ public class ChooseLockPassword extends SettingsActivity {
                    getActivity().setResult(RESULT_FINISHED);
                    getActivity().finish();
                    mDone = true;
                    if (!wasSecureBefore) {
                        startActivity(RedactionInterstitial.createStartIntent(getActivity()));
                    }
                } else {
                    CharSequence tmp = mPasswordEntry.getText();
                    if (tmp != null) {
+5 −1
Original line number Diff line number Diff line
@@ -540,6 +540,8 @@ public class ChooseLockPattern extends SettingsActivity {
            final boolean isFallback = getActivity().getIntent()
                .getBooleanExtra(LockPatternUtils.LOCKSCREEN_BIOMETRIC_WEAK_FALLBACK, false);

            boolean wasSecureBefore = utils.isSecure();

            final boolean required = getActivity().getIntent().getBooleanExtra(
                    EncryptionInterstitial.EXTRA_REQUIRE_PASSWORD, true);
            utils.setCredentialRequiredToDecrypt(required);
@@ -553,7 +555,9 @@ public class ChooseLockPattern extends SettingsActivity {
            getActivity().setResult(RESULT_FINISHED);
            getActivity().finish();
            mDone = true;
            if (!wasSecureBefore) {
                startActivity(RedactionInterstitial.createStartIntent(getActivity()));
            }
        }
    }
}