在触摸进入内容视图之前检测滚动视图上的手指数量
我已经在滚动视图中访问 UIGestureRecognizer
数组,并将 maximumNumberOfTouches
设置为 2
以允许我的一个/两个手指滑动/拖动手势自定义滚动视图。 我想做的事情是识别何时是单指拖动和何时是两指拖动。有办法实现这一点吗?
I am already visiting array of UIGestureRecognizer
in the scrollview and make maximumNumberOfTouches
to be 2
to allow both one/two finger swipe/drag gesture for my custom scrollview.
The thing I want to do is to identify between when it's a one finger drag and when it's a two finger drag. Is there a way to achieve this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
UIGestureRecognizer 的方法 -(NSUInteger)numberOfTouches 可以告诉你有多少次触摸。
The method -(NSUInteger)numberOfTouches of UIGestureRecognizer could tell you how many touches on it.