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

Commit 02b288d6 authored by Rhed Jao's avatar Rhed Jao Committed by Android (Google) Code Review
Browse files

Merge "Support long press accessibility button (1/n)" into rvc-dev

parents 770ba1c9 a4bb7e44
Loading
Loading
Loading
Loading
+12 −0
Original line number Diff line number Diff line
@@ -6607,6 +6607,18 @@ public final class Settings {
        public static final String ACCESSIBILITY_BUTTON_TARGET_COMPONENT =
                "accessibility_button_target_component";
        /**
         * Setting specifying the accessibility services, accessibility shortcut targets,
         * or features to be toggled via the long press accessibility button in the navigation bar.
         *
         * <p> This is a colon-separated string list which contains the flattened
         * {@link ComponentName} and the class name of a system class implementing a supported
         * accessibility feature.
         * @hide
         */
        public static final String ACCESSIBILITY_BUTTON_LONG_PRESS_TARGETS =
                "accessibility_button_long_press_targets";
        /**
         * The system class name of magnification controller which is a target to be toggled via
         * accessibility shortcut or accessibility button.
+1 −0
Original line number Diff line number Diff line
@@ -77,6 +77,7 @@ message SecureSettingsProto {
        optional SettingProto interactive_ui_timeout_ms = 33 [ (android.privacy).dest = DEST_AUTOMATIC ];
        // Settings for magnification mode
        optional SettingProto accessibility_magnification_mode = 34 [ (android.privacy).dest = DEST_AUTOMATIC ];
        optional SettingProto button_long_press_targets = 35 [ (android.privacy).dest = DEST_AUTOMATIC ];
    }
    optional Accessibility accessibility = 2;

+1 −0
Original line number Diff line number Diff line
@@ -162,5 +162,6 @@ public class SecureSettings {
        Settings.Secure.AWARE_TAP_PAUSE_TOUCH_COUNT,
        Settings.Secure.PEOPLE_STRIP,
        Settings.Secure.ACCESSIBILITY_MAGNIFICATION_MODE,
        Settings.Secure.ACCESSIBILITY_BUTTON_LONG_PRESS_TARGETS,
    };
}
+3 −0
Original line number Diff line number Diff line
@@ -245,5 +245,8 @@ public class SecureSettingsValidators {
                new InclusiveIntegerRangeValidator(
                        Secure.ACCESSIBILITY_MAGNIFICATION_MODE_FULLSCREEN,
                        Secure.ACCESSIBILITY_MAGNIFICATION_MODE_WINDOW));
        VALIDATORS.put(
                Secure.ACCESSIBILITY_BUTTON_LONG_PRESS_TARGETS,
                ACCESSIBILITY_SHORTCUT_TARGET_LIST_VALIDATOR);
    }
}
+3 −0
Original line number Diff line number Diff line
@@ -1811,6 +1811,9 @@ class SettingsProtoDumpUtil {
        dumpSetting(s, p,
                Settings.Secure.ACCESSIBILITY_MAGNIFICATION_MODE,
                SecureSettingsProto.Accessibility.ACCESSIBILITY_MAGNIFICATION_MODE);
        dumpSetting(s, p,
                Settings.Secure.ACCESSIBILITY_BUTTON_LONG_PRESS_TARGETS,
                SecureSettingsProto.Accessibility.BUTTON_LONG_PRESS_TARGETS);
        p.end(accessibilityToken);

        final long adaptiveSleepToken = p.start(SecureSettingsProto.ADAPTIVE_SLEEP);