开发者

TouchesEnded event

I have created a view which has an object img which is a subclass of UIImageView and I have added the touchesEnded method to the img class. But when I click on the img class object, the touchesEnded event is not triggered.

Does any开发者_如何学Pythonone have an idea what may be wrong, please?

Thank you!


UIImageView by default has userInteractionEnabled property set to NO so it does not track any touch events. Try to set userInteractionEnabled to YES

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜