IOS UIScrollView - 同时滚动和点击元素

标签 ios uiscrollview

我有一个 UIScrollView,在 scrollView 的内容区域之外有一个按钮。用户必须向上滚动并按住一根手指的 Spring 效果,然后用另一根手指按下按钮。问题是从未检测到按钮上的触摸。

请看下图

The scroll view in it's initial state. the orange area is the scrollView, the white area the button

处于初始状态的 ScrollView 。橙色区域是 ScrollView ,白色区域是按钮

The user is now scrolling and holding with one finger to overcome the spring effect of the UIScrollView, and want to click the button, which is currently not possible

用户现在用一根手指滚动并按住以克服 UIScrollView 的 Spring 效果,并想要单击按钮

有什么建议吗?

最佳答案

检查一下: UIScrollView blocks all touches while zooming or scrolling

确保在 ScrollView 上将多点触控设置为 YES,并且没有任何 subview 启用了独占触摸。

关于IOS UIScrollView - 同时滚动和点击元素,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13414289/

相关文章:

ios - 如何使用 ImageView 制作无限分页 ScrollView ?

objective-c - UIView 未检测到横向触摸

iphone - 获取不同ViewController的下载进度

iphone - 无论 ViewController 用户处于哪个位置,都可以读取/写入 NSStream

android - 你能在智能手机屏幕底部修复 HTML5 页脚吗?

ios - 防止 UIScrollView 重置 contentOffset

ios - 设置包含动态单元格高度的 UITableView 的高度

iphone - 检测 UIScrollView 何时在某个点查看并执行操作

ios - 如何在 UITableView 中填充数据? swift

objective-c - Instruments 中的内存分配过多是否不好?