I have attached 3 tap gesture recognizers to the same view - single, double and triple tap. However, a double tap results in the single and double tap selector being called and the same for a triple tap. I expected that UITapGestureRecognizer class would have handled this situation appropriately. Does multiple tap gestures require additional code? Thank you
Go to Settings > Accessibility > Touch > Back Tap. Choose Double Tap or Triple Tap, then choose an action. To perform the action you set, double-tap or triple-tap the back of iPhone.
A discrete gesture recognizer that interprets single or multiple taps. iOS 3.2+ iPadOS 3.2+ Mac Catalyst 13.1+ tvOS 9.0+
I ended up using only a single tap and a double tap. To get this to work properly, the following line should be added to the single gesture recognizer:
[singleTapGR requireGestureRecognizerToFail:doubleTapGR];
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With