UIView 覆盖另一个 uiview 并传递触摸
我有一个风景坐在另一个风景之上。顶部视图有一个 UITapGestureRecognizer,因此我可以关闭菜单(单击菜单外部)。但是下面的层需要接收所有的触摸。
我可以让单指手势通过,但我无法让捏合手势通过。
I have a view sitting over another view. The top view has a UITapGestureRecognizer so I can close the menus (click outside of the menus). But the layer below this needs to receive all the touches.
I can get single finger gestures to pass through, but I can't get the pinch gesture to pass through.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您需要确保在两个视图中都启用了多次触摸。这样,捏一下就可以识别了!希望有帮助!
You need to make sure that multiple touches are enabled in both views. That way, a pinch can be recognized! Hope that helps!