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

Commit 62f454ea authored by Bruno Martins's avatar Bruno Martins Committed by Rohit Sekhar
Browse files

FingerprintEnroll: Add config for dedicated side mounted fps

Google likes to assume that there only exists devices with
fingerprint sensor embedded in the power button, but that's
not always true.

[merothh]: Backport to A12

Change-Id: I56a7d7fe0374fe5a1fce5e24bdbb265cb5edc246
parent ce74d9dc
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
     Copyright (C) 2020-2022 The LineageOS Project
     Copyright (C) 2020-2023 The LineageOS Project

     Licensed under the Apache License, Version 2.0 (the "License");
     you may not use this file except in compliance with the License.
@@ -18,6 +18,10 @@
    <!-- Indicates whether device has a front facing fingerprint sensor (not udfps). -->
    <bool name="config_is_front_facing_fps" translatable="false">false</bool>

    <!-- Indicates whether device has a side mounted fingerprint sensor,
         but a dedicated one, i.e. not embedded in the power button. -->
    <bool name="config_is_side_fps" translatable="false">false</bool>

    <string-array name="config_ignored_backup_transports" translatable="false">
        <item>com.android.localtransport/.LocalTransport</item>
    </string-array>
+3 −1
Original line number Diff line number Diff line
@@ -743,7 +743,9 @@ public class FingerprintEnrollEnrolling extends BiometricsEnrollEnrolling {
        public Dialog onCreateDialog(Bundle savedInstanceState) {
            final boolean isFrontFacingFps = getResources().getBoolean(
                    R.bool.config_is_front_facing_fps);
            final String fpsLocation = getString(sCanAssumeSidefps
            final boolean isSideMountedfps = sCanAssumeSidefps || getResources().getBoolean(
                    R.bool.config_is_side_fps);
            final String fpsLocation = getString(isSideMountedfps
                    ? R.string.fingerprint_enroll_touch_dialog_message_side : isFrontFacingFps
                            ? R.string.fingerprint_enroll_touch_dialog_message_front
                            : R.string.fingerprint_enroll_touch_dialog_message_rear);
+3 −1
Original line number Diff line number Diff line
@@ -95,7 +95,9 @@ public class FingerprintEnrollFindSensor extends BiometricEnrollBase implements
        } else {
            final boolean isFrontFacingFps = getResources().getBoolean(
                    R.bool.config_is_front_facing_fps);
            final String fpsLocation = getString(mCanAssumeSidefps
            final boolean isSideMountedFps = mCanAssumeSidefps || getResources().getBoolean(
                    R.bool.config_is_side_fps);
            final String fpsLocation = getString(isSideMountedFps
                    ? R.string.fingerprint_enroll_find_sensor_message_side : isFrontFacingFps
                            ? R.string.fingerprint_enroll_find_sensor_message_front
                            : R.string.fingerprint_enroll_find_sensor_message_rear);