开发者

Adding other views to UIButton

开发者 https://www.devze.com 2023-04-13 06:39 出处:网络
I want开发者_高级运维 to add some views to a UIButton. For example multiple UILabels, UIImages, etc.

I want开发者_高级运维 to add some views to a UIButton. For example multiple UILabels, UIImages, etc. One I add those views, they do not get the touch events. How can I pass the touch events to UIButton?

Thanks


Set the userInteractionEnabled property of each of the subviews you added to your UIButton to NO.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号