[BiometricsV2] Fix fingerprint 2nd enroll fail

Enrolling fragments wait cancelled msg then finish itself when user
presses skip button in this page

Bug: 279540275
Test: atest FingerprintEnrollmentActivityTest
Test: For udfps and sfps devices, manually click "Add fingerprint" from
      Fingerprint Settings, then quickly back, and quickly re-enter.
      Make sure the re-entered enrolling works well.
Change-Id: I99b67af31234f7332ad33e776e82d04ece117e5e
This commit is contained in:
Milton Wu
2023-04-27 10:39:25 +00:00
parent cb39261886
commit 1205ba58de
2 changed files with 8 additions and 4 deletions

View File

@@ -104,8 +104,10 @@ public class FingerprintEnrollEnrollingSfpsFragment extends Fragment {
private ObjectAnimator mHelpAnimation;
private int mIconTouchCount;
private final View.OnClickListener mOnSkipClickListener =
(v) -> mEnrollingViewModel.onCancelledDueToOnSkipPressed();
private final View.OnClickListener mOnSkipClickListener = v -> {
mEnrollingViewModel.setOnSkipPressed();
cancelEnrollment();
};
private final Observer<EnrollmentProgress> mProgressObserver = progress -> {
if (DEBUG) {

View File

@@ -95,8 +95,10 @@ public class FingerprintEnrollEnrollingUdfpsFragment extends Fragment {
private int mRotation = -1;
private final View.OnClickListener mOnSkipClickListener =
(v) -> mEnrollingViewModel.onCancelledDueToOnSkipPressed();
private final View.OnClickListener mOnSkipClickListener = v -> {
mEnrollingViewModel.setOnSkipPressed();
cancelEnrollment();
};
private final Observer<EnrollmentProgress> mProgressObserver = progress -> {
if (progress != null) {