Fingerprint should confirm device lock when unified

When unified and adding a fingerprint, the user is prompted to set up
a backup

Bug:27419438
Change-Id: I6cfa8c276ae69a0af51580be390c3da4e9596874
This commit is contained in:
Ricky Wai
2016-04-05 16:33:47 +01:00
parent 4bbf0653c0
commit 996d0dfa6e
5 changed files with 46 additions and 31 deletions

View File

@@ -70,6 +70,7 @@ public abstract class ConfirmDeviceCredentialBaseFragment extends OptionsMenuFra
protected Button mCancelButton;
protected ImageView mFingerprintIcon;
protected int mEffectiveUserId;
protected int mUserId;
protected LockPatternUtils mLockPatternUtils;
protected TextView mErrorTextView;
protected final Handler mHandler = new Handler();
@@ -81,7 +82,9 @@ public abstract class ConfirmDeviceCredentialBaseFragment extends OptionsMenuFra
ALLOW_FP_AUTHENTICATION, false);
// Only take this argument into account if it belongs to the current profile.
Intent intent = getActivity().getIntent();
mEffectiveUserId = Utils.getUserIdFromBundle(getActivity(), intent.getExtras());
mUserId = Utils.getUserIdFromBundle(getActivity(), intent.getExtras());
final UserManager userManager = UserManager.get(getActivity());
mEffectiveUserId = userManager.getCredentialOwnerProfile(mUserId);
mAllowFpAuthentication = mAllowFpAuthentication && !isFingerprintDisabledByAdmin();
mLockPatternUtils = new LockPatternUtils(getActivity());
}