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

Commit 20d43991 authored by Eric Biggers's avatar Eric Biggers Committed by Android (Google) Code Review
Browse files

Merge "locksettings: remove unused code to read/write LEGACY_LOCK_PATTERN_ENABLED"

parents 5dfe36b8 5a0181c4
Loading
Loading
Loading
Loading
+0 −18
Original line number Diff line number Diff line
@@ -76,11 +76,6 @@ public class LockPatternUtils {
    private static final String TAG = "LockPatternUtils";
    private static final boolean FRP_CREDENTIAL_ENABLED = true;

    /**
     * The key to identify when the lock pattern enabled flag is being accessed for legacy reasons.
     */
    public static final String LEGACY_LOCK_PATTERN_ENABLED = "legacy_lock_pattern_enabled";

    /**
     * The interval of the countdown for showing progress of the lockout.
     */
@@ -952,19 +947,6 @@ public class LockPatternUtils {
        return type == CREDENTIAL_TYPE_PATTERN;
    }

    @Deprecated
    public boolean isLegacyLockPatternEnabled(int userId) {
        // Note: this value should default to {@code true} to avoid any reset that might result.
        // We must use a special key to read this value, since it will by default return the value
        // based on the new logic.
        return getBoolean(LEGACY_LOCK_PATTERN_ENABLED, true, userId);
    }

    @Deprecated
    public void setLegacyLockPatternEnabled(int userId) {
        setBoolean(Settings.Secure.LOCK_PATTERN_ENABLED, true, userId);
    }

    /**
     * @return Whether the visible pattern is enabled.
     */
+0 −5
Original line number Diff line number Diff line
@@ -533,11 +533,6 @@ class LockSettingsStorage {
        if (userId == USER_FRP) {
            return null;
        }

        if (LockPatternUtils.LEGACY_LOCK_PATTERN_ENABLED.equals(key)) {
            key = Settings.Secure.LOCK_PATTERN_ENABLED;
        }

        return readKeyValue(key, defaultValue, userId);
    }