- (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event
I am currently getting 1 object in
touches
when I do a tap with two fingers simultaneously (holding option key and clicking on the simulator). I believe this is because I haven't enabled the
multipleTouchEnabled
property of the attached view. I want to make it so that I don't register this event for multi-touches.
Looking into the issue, it seems like it would work if I enable multipleTouchEnabled, and then do
if ([touches count] > 1) {
return;
}
in my
touchesBegan:
However, this seems strange to me in that I am ENABLING multipleTouchEnabled to DISABLE multiple touches, and am worried if there will be side-effects. Is there a better way to solve my problem?
-touchesBegan:
to be called twice (or more) with different touches. – Percaline