Add special lock screen prompt strings for strong auth.

Due to incorrect strings, we temporarily disabled the prompt strings for
strong auth and instead used the generic ones as a short-term fix. In
this CL, we correct the strong auth prompt strings and add them back to
the lock screen UI. The new strings are in line with those in keyguard.

Bug: 36511626
Test: manual
Test: make RunSettingsRoboTests
Change-Id: Ifba689db37cc7d331eb1a774814f6b6235977ff9
This commit is contained in:
Charles He
2017-07-04 11:50:03 +01:00
parent 159461569d
commit 4c96d9b203
3 changed files with 38 additions and 20 deletions

View File

@@ -243,11 +243,15 @@ public class ConfirmLockPattern extends ConfirmDeviceCredentialBaseActivity {
}
private int getDefaultDetails() {
// TODO(b/36511626): add back special strings for strong auth.
final boolean isStrongAuthRequired = isStrongAuthRequired();
if (UserManager.get(getActivity()).isManagedProfile(mEffectiveUserId)) {
return R.string.lockpassword_confirm_your_pattern_generic_profile;
return isStrongAuthRequired
? R.string.lockpassword_strong_auth_required_work_pattern
: R.string.lockpassword_confirm_your_pattern_generic_profile;
} else {
return R.string.lockpassword_confirm_your_pattern_generic;
return isStrongAuthRequired
? R.string.lockpassword_strong_auth_required_device_pattern
: R.string.lockpassword_confirm_your_pattern_generic;
}
}