Pan Gesture阻止普通触摸事件?

时间:2014-05-29 14:36:28

标签: ios ios7 touch ios7.1

我添加了Pan Gesture,发现原始触摸事件不再起作用了吗?

有没有办法让Pan Gesture只拦截两根手指?

1 个答案:

答案 0 :(得分:0)

//...
@interface MyViewController () 


//...
self.panGesture.delegate = self; 

//...
- (BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldRecognizeSimultaneouslyWithGestureRecognizer:(UIGestureRecognizer *)otherGestureRecognizer
{
    return YES;
}