UIScrollView 根本不缩放

发布于 2024-09-18 02:51:46 字数 281 浏览 1 评论 0原文

我制作了一个 UIScrollView,添加了一个 UIImageView 作为子视图,设置 viewForZoomingInScrollView: 方法返回子视图,在我的 viewDidLoad 中将 UIScrollView 的委托设置为 self,将我的 ViewController 设置为 UIScrollView 委托,在 IB 中将 maxZoom 设置为 5.00,我仍然无法滚动

我正在使用 iPhone 模拟器,按选项键让它们变成灰色圆圈,然后移动鼠标,但什么也没有发生。

我有什么想法吗? 干杯

I made a UIScrollView, added a UIImageView to as a subView, set the viewForZoomingInScrollView: method to return the subView, set the UIScrollView's delegate to self in my viewDidLoad, set my ViewController to be a UIScrollView delegate, set the maxZoom to 5.00 in IB, and I still am unable to scroll

I'm using the iPhone simulator, pressing the option key to get they grey circles then moving my mouse, and nothing's happening.

Any ideas what I'm missing?
Cheers

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

荒芜了季节 2024-09-25 02:53:39

您设置了内容大小吗?

Did you set the content size?

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文