When the user single taps my view, i need one specific method to run. When the user double taps, i need another method do take place.
The problem is that the double
Just implement the UIGestureRecognizer delegate methods by setting the delegate properly.
- (BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldReceiveTouch:(UITouch *)touch{
return YES;
}
- (BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldRecognizeSimultaneouslyWithGestureRecognizer:(UIGestureRecognizer *)otherGestureRecognizer{
return YES;
}
Also add this line of code
[singleTap requireGestureRecognizerToFail:doubleTap];