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

Commit 27494b37 authored by Danny Wang's avatar Danny Wang
Browse files

Fix typo in InputSettings and SecureSettingsValidators

Acceleration value should be float instead of int.

Bug: 393566398
Test: manual verified on test Device
Flag: com.android.server.accessibility.enable_mouse_key_enhancement
Change-Id: I8641d8401b8429a75b4dabad3e1ad19ca9905638
parent b297de40
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1137,7 +1137,7 @@ public class InputSettings {
    @FlaggedApi(FLAG_KEYBOARD_A11Y_MOUSE_KEYS)
    @RequiresPermission(Manifest.permission.WRITE_SECURE_SETTINGS)
    public static void setAccessibilityMouseKeysAcceleration(@NonNull Context context,
            int acceleration) {
            float acceleration) {
        if (!isAccessibilityMouseKeysFeatureFlagEnabled()) {
            return;
        }
+1 −1
Original line number Diff line number Diff line
@@ -13023,7 +13023,7 @@ public final class Settings {
                "accessibility_mouse_keys_enabled";
        /**
         * The current acceleration for mouse keys movement.
         * The current float acceleration value for mouse keys movement.
         *
         * @hide
         */
+1 −1
Original line number Diff line number Diff line
@@ -470,7 +470,7 @@ public class SecureSettingsValidators {
        VALIDATORS.put(Secure.ON_DEVICE_INTELLIGENCE_IDLE_TIMEOUT_MS, NONE_NEGATIVE_LONG_VALIDATOR);
        VALIDATORS.put(Secure.ACCESSIBILITY_MOUSE_KEYS_ENABLED, BOOLEAN_VALIDATOR);
        VALIDATORS.put(Secure.ACCESSIBILITY_MOUSE_KEYS_ACCELERATION,
                new InclusiveIntegerRangeValidator(0, 10));
                new InclusiveFloatRangeValidator(0, 1.0f));
        VALIDATORS.put(Secure.ACCESSIBILITY_MOUSE_KEYS_MAX_SPEED,
                new InclusiveIntegerRangeValidator(1, 10));
        VALIDATORS.put(Secure.MANDATORY_BIOMETRICS, new InclusiveIntegerRangeValidator(0, 1));