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

Commit e409aa44 authored by Sally Yuen's avatar Sally Yuen Committed by Automerger Merge Worker
Browse files

Merge "Add javadocs for selection and edit a11y actions" am: 037783ba am:...

Merge "Add javadocs for selection and edit a11y actions" am: 037783ba am: 9eecbc3e am: fc40c1e8 am: 1b9dd4da

Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2615434



Change-Id: I1343781b89b11fd89100be4cf6a066e76c8ead62
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents 623ba499 1b9dd4da
Loading
Loading
Loading
Loading
+15 −23
Original line number Original line Diff line number Diff line
@@ -259,6 +259,7 @@ public class AccessibilityNodeInfo implements Parcelable {


    /**
    /**
     * Action that selects the node.
     * Action that selects the node.
     * @see AccessibilityAction#ACTION_SELECT
     */
     */
    public static final int ACTION_SELECT = 0x00000004;
    public static final int ACTION_SELECT = 0x00000004;


@@ -415,19 +416,8 @@ public class AccessibilityNodeInfo implements Parcelable {
    /**
    /**
     * Action to set the selection. Performing this action with no arguments
     * Action to set the selection. Performing this action with no arguments
     * clears the selection.
     * clears the selection.
     * <p>
     * <strong>Arguments:</strong>
     * {@link #ACTION_ARGUMENT_SELECTION_START_INT},
     * {@link #ACTION_ARGUMENT_SELECTION_END_INT}<br>
     * <strong>Example:</strong>
     * <code><pre><p>
     *   Bundle arguments = new Bundle();
     *   arguments.putInt(AccessibilityNodeInfo.ACTION_ARGUMENT_SELECTION_START_INT, 1);
     *   arguments.putInt(AccessibilityNodeInfo.ACTION_ARGUMENT_SELECTION_END_INT, 2);
     *   info.performAction(AccessibilityNodeInfo.ACTION_SET_SELECTION, arguments);
     * </code></pre></p>
     * </p>
     *
     *
     * @see AccessibilityAction#ACTION_SET_SELECTION
     * @see #ACTION_ARGUMENT_SELECTION_START_INT
     * @see #ACTION_ARGUMENT_SELECTION_START_INT
     * @see #ACTION_ARGUMENT_SELECTION_END_INT
     * @see #ACTION_ARGUMENT_SELECTION_END_INT
     */
     */
@@ -452,16 +442,7 @@ public class AccessibilityNodeInfo implements Parcelable {
     * Action that sets the text of the node. Performing the action without argument, using <code>
     * Action that sets the text of the node. Performing the action without argument, using <code>
     * null</code> or empty {@link CharSequence} will clear the text. This action will also put the
     * null</code> or empty {@link CharSequence} will clear the text. This action will also put the
     * cursor at the end of text.
     * cursor at the end of text.
     * <p>
     * @see AccessibilityAction#ACTION_SET_TEXT
     * <strong>Arguments:</strong>
     * {@link #ACTION_ARGUMENT_SET_TEXT_CHARSEQUENCE}<br>
     * <strong>Example:</strong>
     * <code><pre><p>
     *   Bundle arguments = new Bundle();
     *   arguments.putCharSequence(AccessibilityNodeInfo.ACTION_ARGUMENT_SET_TEXT_CHARSEQUENCE,
     *       "android");
     *   info.performAction(AccessibilityNodeInfo.ACTION_SET_TEXT, arguments);
     * </code></pre></p>
     */
     */
    public static final int ACTION_SET_TEXT = 0x00200000;
    public static final int ACTION_SET_TEXT = 0x00200000;


@@ -5051,12 +5032,16 @@ public class AccessibilityNodeInfo implements Parcelable {


        /**
        /**
         *  Action that selects the node.
         *  Action that selects the node.
         *  The view the implements this should send a
         *  {@link AccessibilityEvent#TYPE_VIEW_SELECTED} event.
         * @see AccessibilityAction#ACTION_CLEAR_SELECTION
         */
         */
        public static final AccessibilityAction ACTION_SELECT =
        public static final AccessibilityAction ACTION_SELECT =
                new AccessibilityAction(AccessibilityNodeInfo.ACTION_SELECT);
                new AccessibilityAction(AccessibilityNodeInfo.ACTION_SELECT);


        /**
        /**
         * Action that deselects the node.
         * Action that deselects the node.
         * @see AccessibilityAction#ACTION_SELECT
         */
         */
        public static final AccessibilityAction ACTION_CLEAR_SELECTION =
        public static final AccessibilityAction ACTION_CLEAR_SELECTION =
                new AccessibilityAction(AccessibilityNodeInfo.ACTION_CLEAR_SELECTION);
                new AccessibilityAction(AccessibilityNodeInfo.ACTION_CLEAR_SELECTION);
@@ -5281,7 +5266,10 @@ public class AccessibilityNodeInfo implements Parcelable {
         *   info.performAction(AccessibilityAction.ACTION_SET_SELECTION.getId(), arguments);
         *   info.performAction(AccessibilityAction.ACTION_SET_SELECTION.getId(), arguments);
         * </code></pre></p>
         * </code></pre></p>
         * </p>
         * </p>
         *
         * <p> If this is a text selection, the UI element that implements this should send a
         * {@link AccessibilityEvent#TYPE_VIEW_TEXT_SELECTION_CHANGED} event if its selection is
         * updated. This element should also return {@code true} for
         * {@link AccessibilityNodeInfo#isTextSelectable()}.
         * @see AccessibilityNodeInfo#ACTION_ARGUMENT_SELECTION_START_INT
         * @see AccessibilityNodeInfo#ACTION_ARGUMENT_SELECTION_START_INT
         *  AccessibilityNodeInfo.ACTION_ARGUMENT_SELECTION_START_INT
         *  AccessibilityNodeInfo.ACTION_ARGUMENT_SELECTION_START_INT
         * @see AccessibilityNodeInfo#ACTION_ARGUMENT_SELECTION_END_INT
         * @see AccessibilityNodeInfo#ACTION_ARGUMENT_SELECTION_END_INT
@@ -5323,6 +5311,10 @@ public class AccessibilityNodeInfo implements Parcelable {
         *       "android");
         *       "android");
         *   info.performAction(AccessibilityAction.ACTION_SET_TEXT.getId(), arguments);
         *   info.performAction(AccessibilityAction.ACTION_SET_TEXT.getId(), arguments);
         * </code></pre></p>
         * </code></pre></p>
         * <p> The UI element that implements this should send a
         * {@link AccessibilityEvent#TYPE_VIEW_TEXT_CHANGED} event if its text is updated.
         * This element should also return {@code true} for
         * {@link AccessibilityNodeInfo#isEditable()}.
         */
         */
        public static final AccessibilityAction ACTION_SET_TEXT =
        public static final AccessibilityAction ACTION_SET_TEXT =
                new AccessibilityAction(AccessibilityNodeInfo.ACTION_SET_TEXT);
                new AccessibilityAction(AccessibilityNodeInfo.ACTION_SET_TEXT);