UITapGestureRecognizer* singleTapGesture = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(handleSingleTapGesture:)];
[self.view addGestureRecognizer:singleTapGesture];
UITapGestureRecognizer* doubleTapGesture = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(handleDoubleTapGesture:)];
[doubleTapGesture setNumberOfTapsRequired:2];
[self.view addGestureRecognizer:doubleTapGesture];
- (void)handleSingleTapGesture:(UITapGestureRecognizer*)sender
{
NSLog(@"single tap");
}
- (void) handleDoubleTapGesture:(UITapGestureRecognizer*)sender
{
NSLog(@"double tap");
}