1
votes

I have a subclass of UIScrollView that implements this method:

-(void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event
{
     NSLog(@"touches: %d", [[event allTouches] count]);


    [self.nextResponder touchesBegan:touches withEvent:event];
}

This gets called when I first touch the scroll view. However, if I begin dragging the scroll view, then place a second finger down, touchesBegan does not get called. I need to detect when a second touch has occured in the scrollview, even if it is currently scrolling. Any ideas?

EDIT: Two touches are registered if I start with two, but if I start with one, begin scrolling, then put a 2nd finger down it is not registered.

1

1 Answers

0
votes

Make sure multipleTouchEnabled is set to YES on your scroll view.

You can also set this in Interface Builder. Look for 'Multiple Touch' checkbox.