AccessibilityServiceInfo.MotionEventSources Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Returns the bit mask of android.view.InputDevice
sources that the accessibility
service wants to listen to for generic android.view.MotionEvent
s. -or- Sets the bit mask of android.view.InputDevice
sources that the accessibility
service wants to listen to for generic android.view.MotionEvent
s.
public virtual Android.Views.InputSourceType MotionEventSources { [Android.Runtime.Register("getMotionEventSources", "()I", "GetGetMotionEventSourcesHandler", ApiSince=34)] get; [Android.Runtime.Register("setMotionEventSources", "(I)V", "GetSetMotionEventSources_IHandler", ApiSince=34)] set; }
[<get: Android.Runtime.Register("getMotionEventSources", "()I", "GetGetMotionEventSourcesHandler", ApiSince=34)>]
[<set: Android.Runtime.Register("setMotionEventSources", "(I)V", "GetSetMotionEventSources_IHandler", ApiSince=34)>]
member this.MotionEventSources : Android.Views.InputSourceType with get, set
Property Value
- Attributes
Remarks
Property getter documentation:
Returns the bit mask of android.view.InputDevice
sources that the accessibility service wants to listen to for generic android.view.MotionEvent
s.
Property setter documentation:
Sets the bit mask of android.view.InputDevice
sources that the accessibility service wants to listen to for generic android.view.MotionEvent
s.
Including an android.view.InputDevice
source that does not send android.view.MotionEvent
s is effectively a no-op for that source, since you will not receive any events from that source.
See android.view.InputDevice
for complete source definitions. Many input devices send android.view.InputEvent
s from more than one type of source so you may need to include multiple android.view.MotionEvent
sources here, in addition to using AccessibilityService#onKeyEvent
to listen to android.view.KeyEvent
s.
<strong>Note:</strong> android.view.InputDevice
sources contain source class bits that complicate bitwise flag removal operations. To remove a specific source you should rebuild the entire value using bitwise OR operations on the individual source constants.
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.