Extends Gesture
Gesture.SingleTouch
Gesture.SingleTouch is used to implement custom, single-touch gestures.
Single-touch gestures only respond to their primary touch point, with subsequent points being ignored. If you would like to handle multiple touch points, use Gesture.MultiTouch instead.
event pressed(Gesture.SingleTouch.Event e)
event moved(Gesture.SingleTouch.Event e)
event released(Gesture.SingleTouch.Event e)
event finished()
Events emitted when the primary touch point is pressed, moved and released.
You should never assume you will always receive the released() event, as it is not emitted if the gesture is canceled or fails.
Unlike the released() event, finished() is always emitted when the gesture finishes, even in the case of cancelation or failure.
property Bool isPressedread only
property Float touchXread only
property Float touchYread only
These properties represent the current state of the gesture.
isPressed becomes true when the gesture begins, and remains true until the initial touch point is released, or the gesture is canceled or fails.
The touchX and touchY properties are the current x and y coordinates of the touch, or zero if the gesture is not in progress.
event canceled()
Emitted if the gesture is cancelled. The gesture is canceled if another, non-concurrent gesture is recognized.