diff options
author | Selim Cinek <cinek@google.com> | 2015-09-12 00:28:09 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2015-09-12 00:28:09 +0000 |
commit | cda53c5dc2c6a2c01dfd5db278a7899dd868da7d (patch) | |
tree | 372e294d880d4e76b27f94e4d47fa054eee8197a | |
parent | 5bd836aac3b7602a4166bc836aaa33ccc7107d74 (diff) | |
parent | 2547ea5b58cb396f7cf71046d0602548081ac2f8 (diff) | |
download | packages_apps_Settings-cda53c5dc2c6a2c01dfd5db278a7899dd868da7d.zip packages_apps_Settings-cda53c5dc2c6a2c01dfd5db278a7899dd868da7d.tar.gz packages_apps_Settings-cda53c5dc2c6a2c01dfd5db278a7899dd868da7d.tar.bz2 |
Merge "Fixed a bug where the ConfirmDeviceCredentials activity was shown twice." into mnc-dr-dev
-rw-r--r-- | src/com/android/settings/fingerprint/FingerprintEnrollFindSensor.java | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/src/com/android/settings/fingerprint/FingerprintEnrollFindSensor.java b/src/com/android/settings/fingerprint/FingerprintEnrollFindSensor.java index a6b0dca..63d9335 100644 --- a/src/com/android/settings/fingerprint/FingerprintEnrollFindSensor.java +++ b/src/com/android/settings/fingerprint/FingerprintEnrollFindSensor.java @@ -16,7 +16,6 @@ package com.android.settings.fingerprint; -import android.content.Context; import android.content.Intent; import android.hardware.fingerprint.FingerprintManager; import android.os.Bundle; @@ -32,15 +31,19 @@ public class FingerprintEnrollFindSensor extends FingerprintEnrollBase { private static final int CONFIRM_REQUEST = 1; private static final int ENROLLING = 2; + public static final String EXTRA_KEY_LAUNCHED_CONFIRM = "launched_confirm_lock"; private FingerprintLocationAnimationView mAnimation; + private boolean mLaunchedConfirmLock; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.fingerprint_enroll_find_sensor); setHeaderText(R.string.security_settings_fingerprint_enroll_find_sensor_title); - if (mToken == null) { + mLaunchedConfirmLock = savedInstanceState != null && savedInstanceState.getBoolean( + EXTRA_KEY_LAUNCHED_CONFIRM); + if (mToken == null && !mLaunchedConfirmLock) { launchConfirmLock(); } mAnimation = (FingerprintLocationAnimationView) findViewById( @@ -60,6 +63,12 @@ public class FingerprintEnrollFindSensor extends FingerprintEnrollBase { } @Override + public void onSaveInstanceState(Bundle outState) { + super.onSaveInstanceState(outState); + outState.putBoolean(EXTRA_KEY_LAUNCHED_CONFIRM, mLaunchedConfirmLock); + } + + @Override protected void onNextButtonClick() { startActivityForResult(getEnrollingIntent(), ENROLLING); } @@ -107,6 +116,8 @@ public class FingerprintEnrollFindSensor extends FingerprintEnrollBase { // This shouldn't happen, as we should only end up at this step if a lock thingy is // already set. finish(); + } else { + mLaunchedConfirmLock = true; } } |