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

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

Merge "Add javadocs to click accessibility actions" am: 05a98342

parents 2c813ef7 05a98342
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -440,12 +440,16 @@ public final class AccessibilityEvent extends AccessibilityRecord implements Par
    /**
     * Represents the event of clicking on a {@link android.view.View} like
     * {@link android.widget.Button}, {@link android.widget.CompoundButton}, etc.
     * <p>See {@link AccessibilityNodeInfo.AccessibilityAction#ACTION_CLICK} for more
     * details.
     */
    public static final int TYPE_VIEW_CLICKED = 0x00000001;

    /**
     * Represents the event of long clicking on a {@link android.view.View} like
     * {@link android.widget.Button}, {@link android.widget.CompoundButton}, etc.
     * <p>See {@link AccessibilityNodeInfo.AccessibilityAction#ACTION_LONG_CLICK} for more
     * details.
     */
    public static final int TYPE_VIEW_LONG_CLICKED = 0x00000002;

@@ -563,6 +567,8 @@ public final class AccessibilityEvent extends AccessibilityRecord implements Par

    /**
     * Represents the event of a context click on a {@link android.view.View}.
     * <p>See {@link AccessibilityNodeInfo.AccessibilityAction#ACTION_CONTEXT_CLICK} for more
     * details.
     */
    public static final int TYPE_VIEW_CONTEXT_CLICKED = 0x00800000;

+32 −2
Original line number Diff line number Diff line
@@ -251,7 +251,7 @@ public class AccessibilityNodeInfo implements Parcelable {
    /**
     * Action that clicks on the node info.
     *
     * See {@link AccessibilityAction#ACTION_CLICK}
     * @see AccessibilityAction#ACTION_CLICK
     */
    public static final int ACTION_CLICK = 0x00000010;

@@ -259,6 +259,7 @@ public class AccessibilityNodeInfo implements Parcelable {
     * Action that long clicks on the node.
     *
     * <p>It does not support coordinate information for anchoring.</p>
     * @see AccessibilityAction#ACTION_LONG_CLICK
     */
    public static final int ACTION_LONG_CLICK = 0x00000020;

@@ -4679,7 +4680,7 @@ public class AccessibilityNodeInfo implements Parcelable {
     * and handled by custom widgets. i.e. ones that are not part of the UI toolkit. For
     * example, an application may define a custom action for clearing the user history.
     * </li>
     * <li><strong>Overriden standard actions</strong> - These are actions that override
     * <li><strong>Overridden standard actions</strong> - These are actions that override
     * standard actions to customize them. For example, an app may add a label to the
     * standard {@link #ACTION_CLICK} action to indicate to the user that this action clears
     * browsing history.
@@ -4729,12 +4730,29 @@ public class AccessibilityNodeInfo implements Parcelable {

        /**
         * Action that clicks on the node info.
         *
         * <p>The UI element that implements this should send a
         * {@link AccessibilityEvent#TYPE_VIEW_CLICKED} event. In the View system,
         * the default handling of this action when performed by a service is to call
         * {@link View#performClick()}, and setting a
         * {@link View#setOnClickListener(View.OnClickListener)} automatically adds this action.
         *
         * <p>{@link #isClickable()} should return true if this action is available.
         */
        public static final AccessibilityAction ACTION_CLICK =
                new AccessibilityAction(AccessibilityNodeInfo.ACTION_CLICK);

        /**
         * Action that long clicks on the node.
         *
         * <p>The UI element that implements this should send a
         * {@link AccessibilityEvent#TYPE_VIEW_LONG_CLICKED} event. In the View system,
         * the default handling of this action when performed by a service is to call
         * {@link View#performLongClick()}, and setting a
         * {@link View#setOnLongClickListener(View.OnLongClickListener)} automatically adds this
         * action.
         *
         * <p>{@link #isLongClickable()} should return true if this action is available.
         */
        public static final AccessibilityAction ACTION_LONG_CLICK =
                new AccessibilityAction(AccessibilityNodeInfo.ACTION_LONG_CLICK);
@@ -5047,6 +5065,18 @@ public class AccessibilityNodeInfo implements Parcelable {

        /**
         * Action that context clicks the node.
         *
         * <p>The UI element that implements this should send a
         * {@link AccessibilityEvent#TYPE_VIEW_CONTEXT_CLICKED} event. In the View system,
         * the default handling of this action when performed by a service is to call
         * {@link View#performContextClick()}, and setting a
         * {@link View#setOnContextClickListener(View.OnContextClickListener)} automatically adds
         * this action.
         *
         * <p>A context click usually occurs from a mouse pointer right-click or a stylus button
         * press.
         *
         * <p>{@link #isContextClickable()} should return true if this action is available.
         */
        public static final AccessibilityAction ACTION_CONTEXT_CLICK =
                new AccessibilityAction(R.id.accessibilityActionContextClick);