Improves flow for fingerprint

This reduces the # of screens, and makes the backup lock choice
for fingerprint more obvious that it is a backup.

bug:26377096
Change-Id: I4e75e1f3302c286587de106bcdf43537bda03390
This commit is contained in:
Udam Saini
2016-01-25 08:06:57 -08:00
parent 3833c6f8ec
commit bf1483c383
4 changed files with 70 additions and 10 deletions

View File

@@ -300,6 +300,7 @@ public class ChooseLockGeneric extends SettingsActivity {
}
addPreferencesFromResource(R.xml.security_settings_picker);
disableUnusablePreferences(quality, hideDisabledPrefs);
updatePreferenceText();
updateCurrentPreference();
updatePreferenceSummaryIfNeeded();
} else {
@@ -307,6 +308,19 @@ public class ChooseLockGeneric extends SettingsActivity {
}
}
private void updatePreferenceText() {
if (mForFingerprint) {
Preference pattern = findPreference(KEY_UNLOCK_SET_PATTERN);
pattern.setTitle(R.string.fingerprint_unlock_set_unlock_pattern);
Preference pin = findPreference(KEY_UNLOCK_SET_PIN);
pin.setTitle(R.string.fingerprint_unlock_set_unlock_pin);
Preference password = findPreference(KEY_UNLOCK_SET_PASSWORD);
password.setTitle(R.string.fingerprint_unlock_set_unlock_password);
}
}
private void updateCurrentPreference() {
String currentKey = getKeyForCurrent();
Preference preference = findPreference(currentKey);