I have a view which contains several subviews which are complex controls with several buttons. The superview has gesture recognizers for taps, swipes etc.
In some cases, when receiving a single or double touch I would like the superview to pass the gesture recognizer to the subview for treatment.
For instance:
singletaprecognizer = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(onSingleTapGestureRecognizerDetected:)];
- (void)onSingleTapGestureRecognizerDetected:(UITapGestureRecognizer*)theTapGestureRecognizer
{
if (someCaseHappens) {
// do something with the gesture - for instance - move a control from one place to another or some other UI action in the superview
}
else {
// the subview will need to get the gesture and do something with it (imagine the touch was inside a button in a subview - the top superview should disregard the gesture and the button should be pressed) - THIS ISN"T HAPPENING NOW
}
}