开发者

iPhone UIButton Parent Frame Changing Touch Up Inside Event Issue

I have a UIButton within a UIView. The button is docked on the bottom of the view using the Autoresizing Masks. The button is working fine when the view initially loads and the IBAction is being called successfully.

开发者_高级运维Now when I resize the height of the parent view the button stays docked at the bottom of the view, however now only half of the button responds to the touch events. If I resize the parent view height a bit larger then the button completely doesn't respond anymore.

Any ideas why this would be occurring?


It sounds as if you've got another view, most likely a transparent one, that is resizing improperly and covering up part of the button.


It seems that I was moving the main view as the inner view height was changing. I guess if the UIButton is outside the bounds of the self.view then touches are not received.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜