Language

AccessibilityServiceFlags Enum

Definition

Enumerates values returned by several types and taken as a parameter of the F:Android.AccessibilityServices.AccessibilityServiceInfo.FlagToString member.

This enumeration supports a bitwise combination of its member values.

[System.Flags]
public enum AccessibilityServiceFlags
[<System.Flags>]
type AccessibilityServiceFlags = 
Inheritance
AccessibilityServiceFlags
Attributes

Fields

Name Value Description
Default 1

If an AccessibilityServiceis the default for a given type. Default service is invoked only if no package specific one exists.

IncludeNotImportantViews 2

If this flag is set the system will regard views that are not important for accessibility in addition to the ones that are important for accessibility.

RequestTouchExplorationMode 4

This flag requests that the system gets into touch exploration mode. In this mode a single finger moving on the screen behaves as a mouse pointer hovering over the user interface.

RequestEnhancedWebAccessibility 8

This flag requests from the system to enable web accessibility enhancing extensions.

ReportViewIds 16

This flag requests that the AccessibilityNodeInfos obtained by an AccessibilityService contain the id of the source view. The source view id will be a fully qualified resource name of the form "package:id/name", for example "foo.bar:id/my_list", and it is useful for UI test automation. This flag is not set by default.

Android reference for android.accessibilityservice.AccessibilityServiceInfo.FLAG_REPORT_VIEW_IDS.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

RequestFilterKeyEvents 32

This flag requests from the system to filter key events.

RetrieveInteractiveWindows 64

This flag indicates to the system that the accessibility service wants to access content of all interactive windows. An interactive window is a window that has input focus or can be touched by a sighted user when explore by touch is not enabled. If this flag is not set your service will not receive AccessibilityEvent.TYPE_WINDOWS_CHANGED events, calling AccessibilityService.getWindows() will return an empty list, and AccessibilityNodeInfo.getWindow() will return null.

Services that want to set this flag have to declare the capability to retrieve window content in their meta-data by setting the attribute canRetrieveWindowContent to true, otherwise this flag will be ignored. For how to declare the meta-data of a service refer to AccessibilityService.SERVICE_META_DATA.

Android reference for android.accessibilityservice.AccessibilityServiceInfo.FLAG_RETRIEVE_INTERACTIVE_WINDOWS.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

EnableAccessibilityVolume 128

This flag requests that all audio tracks system-wide with AudioAttributes.USAGE_ASSISTANCE_ACCESSIBILITY be controlled by the AudioManager.STREAM_ACCESSIBILITY volume.

Android reference for android.accessibilityservice.AccessibilityServiceInfo.FLAG_ENABLE_ACCESSIBILITY_VOLUME.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

RequestAccessibilityButton 256

This flag indicates to the system that the accessibility service requests that an accessibility button be shown within the system's navigation area, if available.

Note: For accessibility services targeting APIs greater than API 29, this flag must be specified in the accessibility service metadata file. Otherwise, it will be ignored.

Android reference for android.accessibilityservice.AccessibilityServiceInfo.FLAG_REQUEST_ACCESSIBILITY_BUTTON.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

RequestFingerprintGestures 512

This flag requests that all fingerprint gestures be sent to the accessibility service.

Services that want to set this flag have to declare the capability to retrieve window content in their meta-data by setting the attribute R.attr.canRequestFingerprintGestures to true, otherwise this flag will be ignored. For how to declare the meta-data of a service refer to AccessibilityService.SERVICE_META_DATA.

Android reference for android.accessibilityservice.AccessibilityServiceInfo.FLAG_REQUEST_FINGERPRINT_GESTURES.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

RequestShortcutWarningDialogSpokenFeedback 1024

This flag requests that accessibility shortcut warning dialog has spoken feedback when dialog is shown.

Android reference for android.accessibilityservice.AccessibilityServiceInfo.FLAG_REQUEST_SHORTCUT_WARNING_DIALOG_SPOKEN_FEEDBACK.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

ServiceHandlesDoubleTap 2048

This flag requests that when FLAG_REQUEST_TOUCH_EXPLORATION_MODE is enabled, double tap and double tap and hold gestures are dispatched to the service rather than being handled by the framework. If FLAG_REQUEST_TOUCH_EXPLORATION_MODE is disabled this flag has no effect.

Android reference for android.accessibilityservice.AccessibilityServiceInfo.FLAG_SERVICE_HANDLES_DOUBLE_TAP.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

RequestMultiFingerGestures 4096

This flag requests that when FLAG_REQUEST_TOUCH_EXPLORATION_MODE is enabled, multi-finger gestures are also enabled. As a consequence, two-finger bypass gestures will be disabled. If FLAG_REQUEST_TOUCH_EXPLORATION_MODE is disabled this flag has no effect.

Android reference for android.accessibilityservice.AccessibilityServiceInfo.FLAG_REQUEST_MULTI_FINGER_GESTURES.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

RequestTwoFingerPassthrough 8192

This flag requests that when FLAG_REQUEST_MULTI_FINGER_GESTURES is enabled, two-finger passthrough gestures are re-enabled. Two-finger swipe gestures are not detected, but instead passed through as one-finger gestures. In addition, three-finger swipes from the bottom of the screen are not detected, and instead are passed through unchanged. If FLAG_REQUEST_MULTI_FINGER_GESTURES is disabled this flag has no effect.

Android reference for android.accessibilityservice.AccessibilityServiceInfo.FLAG_REQUEST_2_FINGER_PASSTHROUGH.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

SendMotionEvents 16384

This flag requests that when FLAG_REQUEST_TOUCH_EXPLORATION_MODE is enabled, a service will receive the motion events for each successfully-detected gesture. The service will also receive an AccessibilityGestureEvent of type GESTURE_INVALID for each cancelled gesture along with its motion events. A service will receive a gesture of type GESTURE_PASSTHROUGH and accompanying motion events for every passthrough gesture that does not start gesture detection. This information can be used to collect instances of improper gesture detection behavior and relay that information to framework developers. If FLAG_REQUEST_TOUCH_EXPLORATION_MODE is disabled this flag has no effect.

Android reference for android.accessibilityservice.AccessibilityServiceInfo.FLAG_SEND_MOTION_EVENTS.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

FlagInputMethodEditor 32768

This flag makes the AccessibilityService an input method editor with a subset of input method editor capabilities: get the InputConnection and get text selection change notifications.

Android reference for android.accessibilityservice.AccessibilityServiceInfo.FLAG_INPUT_METHOD_EDITOR.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Remarks

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to