diff options
author | Jim Miller <jaggies@google.com> | 2015-07-14 21:02:00 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2015-07-14 21:02:02 +0000 |
commit | e641e7d706095b54ac89f6fcb58c66e2190f46c7 (patch) | |
tree | 0d82b3030126209e0ea492736ed2c7a968530dd4 | |
parent | acc70a3a3262aef48b2efab90f14328f818a9aef (diff) | |
parent | e9785ac1e4b779b6119460a5cdc71bce4d6563b9 (diff) | |
download | packages_apps_Settings-e641e7d706095b54ac89f6fcb58c66e2190f46c7.tar.gz packages_apps_Settings-e641e7d706095b54ac89f6fcb58c66e2190f46c7.tar.bz2 packages_apps_Settings-e641e7d706095b54ac89f6fcb58c66e2190f46c7.zip |
Merge "Postpone call to postEnroll() until we actually leave activity." into mnc-dev
-rw-r--r-- | src/com/android/settings/fingerprint/FingerprintSettings.java | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/src/com/android/settings/fingerprint/FingerprintSettings.java b/src/com/android/settings/fingerprint/FingerprintSettings.java index 3962f2244..b070a0ae9 100644 --- a/src/com/android/settings/fingerprint/FingerprintSettings.java +++ b/src/com/android/settings/fingerprint/FingerprintSettings.java @@ -141,6 +141,7 @@ public class FingerprintSettings extends SubSettings { mHandler.obtainMessage(MSG_FINGER_AUTH_SUCCESS, fingerId, 0).sendToTarget(); } + @Override public void onAuthenticationFailed() { mHandler.obtainMessage(MSG_FINGER_AUTH_FAIL).sendToTarget(); }; @@ -174,6 +175,7 @@ public class FingerprintSettings extends SubSettings { } }; private final Handler mHandler = new Handler() { + @Override public void handleMessage(android.os.Message msg) { switch (msg.what) { case MSG_REFRESH_FINGERPRINT_TEMPLATES: @@ -431,8 +433,6 @@ public class FingerprintSettings extends SubSettings { ChooseLockSettingsHelper.EXTRA_KEY_CHALLENGE_TOKEN); } } - } else if (requestCode == ADD_FINGERPRINT_REQUEST) { - int result = mFingerprintManager.postEnroll(); } if (mToken == null) { @@ -441,6 +441,15 @@ public class FingerprintSettings extends SubSettings { } } + @Override + public void onDestroy() { + super.onDestroy(); + int result = mFingerprintManager.postEnroll(); + if (result < 0) { + Log.w(TAG, "postEnroll failed: result = " + result); + } + } + private Drawable getHighlightDrawable() { if (mHighlightDrawable == null) { final Activity activity = getActivity(); |