Help prepare for 2025 → Answer 8 simple questions on our Fall Survey
Open Survey
GesturesObserver
Provides options for the GesturesObserver.

Summary

Constructors

constructor

new GesturesObserver(target: View, callback: (args: GestureEventData) => void, context: any): GesturesObserver
Creates an instance of GesturesObserver class.
Parameter Default Description
target

The view for which the observer is created.

callback
(args: GestureEventData) => void

A function that will be executed when a gesture is received.

context
any

default this argument for the callbacks.

Properties

androidOnTouchEvent

androidOnTouchEvent: (motionEvent: any) => void

callback

context

context: any
A context which will be used as `this` in callback execution.

type

Gesture type attached to the observer.

Methods

disconnect

disconnect(): any
Disconnects the gesture observer.
Returns any

observe

observe(type: GestureTypes): any
Registers a gesture observer to a view and gesture.
Parameter Default Description
type

Type of the gesture.

Returns any
Previous
Frame