Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Unverified Commit 8efda1fd authored by LuK1337's avatar LuK1337 Committed by Michael Bestas
Browse files

Settings: Switch back to udfps_enroll_enrolling_non_scroll layout

New one seems halfbaked? The UDFPS icon is misaligned when using it and
progress circle is missing.

Change-Id: I19d0a1ff973d79381f0f315469c823afedde9c02
parent 5c80ff78
Loading
Loading
Loading
Loading
+1 −32
Original line number Diff line number Diff line
@@ -249,30 +249,12 @@ public class FingerprintEnrollEnrolling extends BiometricsEnrollEnrolling {

            final UdfpsEnrollEnrollingView layout =
                    (UdfpsEnrollEnrollingView) getLayoutInflater().inflate(
                            Flags.enrollLayoutTruncateImprovement()
                                    ? R.layout.udfps_enroll_enrolling :
                            R.layout.udfps_enroll_enrolling_non_scroll, null, false);
            setUdfpsEnrollHelper();
            layout.initView(props.get(0), mUdfpsEnrollHelper, mAccessibilityManager);
            setContentView(layout);
            setDescriptionText(R.string.security_settings_udfps_enroll_start_message);

            if (Flags.enrollLayoutTruncateImprovement() && isPortrait) {
                final UdfpsEnrollEnrollingView layoutView = (UdfpsEnrollEnrollingView) getLayout();
                if (layoutView != null) {
                    final ScrollView headerScrollView = layout.findViewById(
                            R.id.sud_header_scroll_view);
                    if (headerScrollView != null) {
                        final long headerScrollDuration = getResources().getInteger(
                                R.integer.config_biometrics_header_scroll_duration);
                        layoutView.adjustScrollableHeaderHeight(
                                headerScrollView, mShouldShowLottie);
                        layoutView.headerVerticalScrolling(headerScrollView, headerScrollDuration,
                                mIsAccessibilityEnabled);
                    }
                }
            }

        } else if (mCanAssumeSfps) {
            mSfpsEnrollmentFeature = FeatureFactory.getFeatureFactory()
                    .getFingerprintFeatureProvider().getSfpsEnrollmentFeature();
@@ -1236,19 +1218,6 @@ public class FingerprintEnrollEnrolling extends BiometricsEnrollEnrolling {
    @Override
    public void onWindowFocusChanged(boolean hasWindowFocus) {
        super.onWindowFocusChanged(hasWindowFocus);
        if (Flags.enrollLayoutTruncateImprovement()) {
            adjustEnrollViewIfOverlappedWithFooterBar();
        }
    }

    private void adjustEnrollViewIfOverlappedWithFooterBar() {
        if (mCanAssumeUdfps) {
            final UdfpsEnrollEnrollingView layoutView = (UdfpsEnrollEnrollingView) getLayout();
            if (layoutView != null) {
                layoutView.adjustUdfpsVieWithFooterBar();
                layoutView.onUdfpsSensorRectUpdated();
            }
        }
    }

    public static class IconTouchDialog extends InstrumentedDialogFragment {