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

Commit 38c9e553 authored by Treehugger Robot's avatar Treehugger Robot Committed by Android (Google) Code Review
Browse files

Merge "[Screen off unlock UDFPS] Settings integration 1/2" into main

parents 33348763 b08920ab
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -16,6 +16,8 @@

package android.hardware.display;

import static android.provider.Settings.Secure.SCREEN_OFF_UNLOCK_UDFPS_ENABLED;

import android.annotation.TestApi;
import android.content.Context;
import android.hardware.biometrics.Flags;
@@ -151,8 +153,8 @@ public class AmbientDisplayConfiguration {
    public boolean screenOffUdfpsEnabled(int user) {
        return !TextUtils.isEmpty(udfpsLongPressSensorType())
                && ((mScreenOffUdfpsEnabledByDefault && Flags.screenOffUnlockUdfps())
                ? boolSettingDefaultOn("screen_off_udfps_enabled", user)
                : boolSettingDefaultOff("screen_off_udfps_enabled", user));
                ? boolSettingDefaultOn(SCREEN_OFF_UNLOCK_UDFPS_ENABLED, user)
                : boolSettingDefaultOff(SCREEN_OFF_UNLOCK_UDFPS_ENABLED, user));
    }

    /** @hide */
+6 −0
Original line number Diff line number Diff line
@@ -11084,6 +11084,12 @@ public final class Settings {
         */
        public static final String SFPS_PERFORMANT_AUTH_ENABLED = "sfps_performant_auth_enabled_v2";
        /**
         * Whether or not the UDFPS device is enabling the screen off unlock settings.
         * @hide
         */
        public static final String SCREEN_OFF_UNLOCK_UDFPS_ENABLED = "screen_off_udfps_enabled";
        /**
         * Whether or not debugging is enabled.
         * @hide
+1 −0
Original line number Diff line number Diff line
@@ -133,6 +133,7 @@ public class SecureSettings {
        Settings.Secure.FINGERPRINT_SIDE_FPS_ENROLL_TAP_WINDOW,
        Settings.Secure.FINGERPRINT_SIDE_FPS_AUTH_DOWNTIME,
        Settings.Secure.SFPS_PERFORMANT_AUTH_ENABLED,
        Settings.Secure.SCREEN_OFF_UNLOCK_UDFPS_ENABLED,
        Settings.Secure.ACTIVE_UNLOCK_ON_WAKE,
        Settings.Secure.ACTIVE_UNLOCK_ON_UNLOCK_INTENT,
        Settings.Secure.ACTIVE_UNLOCK_ON_UNLOCK_INTENT_LEGACY,
+1 −0
Original line number Diff line number Diff line
@@ -190,6 +190,7 @@ public class SecureSettingsValidators {
                NON_NEGATIVE_INTEGER_VALIDATOR);
        VALIDATORS.put(Secure.FINGERPRINT_SIDE_FPS_AUTH_DOWNTIME, NON_NEGATIVE_INTEGER_VALIDATOR);
        VALIDATORS.put(Secure.SFPS_PERFORMANT_AUTH_ENABLED, BOOLEAN_VALIDATOR);
        VALIDATORS.put(Secure.SCREEN_OFF_UNLOCK_UDFPS_ENABLED, BOOLEAN_VALIDATOR);
        VALIDATORS.put(Secure.SHOW_MEDIA_WHEN_BYPASSING, BOOLEAN_VALIDATOR);
        VALIDATORS.put(Secure.FACE_UNLOCK_APP_ENABLED, BOOLEAN_VALIDATOR);
        VALIDATORS.put(Secure.FACE_UNLOCK_ALWAYS_REQUIRE_CONFIRMATION, BOOLEAN_VALIDATOR);