Instance Property


A Boolean property that indicates whether the gesture recognizer is enabled.


var isEnabled: Bool { get set }


Disables a gesture recognizers so it does not receive touches. The default value is true. If you change this property to false while a gesture recognizer is currently recognizing a gesture, the gesture recognizer transitions to a cancelled state.

See Also

Getting the Recognizer’s State and View

var state: UIGestureRecognizer.State

The current state of the gesture recognizer.

var view: UIView?

The view the gesture recognizer is attached to.

var buttonMask: UIEvent.ButtonMask

A bit mask of the button (or buttons) in the gesture represented by the receiver.

var modifierFlags: UIKeyModifierFlags

The bit mask of modifier flags in the gesture represented by the receiver.