Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一张图片,当我按下该徽标或图片时,我想启动 url,如何为该图片视图实施 ib 操作...任何人都可以建议我在 ib 中选择图片视图来放置我的徽标,对吗?
UIImageView不是的子类,UIControl因此它不支持目标动作机制。您有 2 个选项:
UIImageView
UIControl
UIButton
userInteractionEnabled = YES;