开发者

go back to main view

Hello I have a main 开发者_如何学运维view and I add another view with add subview. Then I add and 3rd view with add subview. Now I want to go back on the main view. How will I do that? (I cant use addsubview:view or _view)


I'm not exactely sure what you mean by "going back" to the mainview, but you can send messages to your superview via delegation. Just set a delegate in your subview and set it to self upon adding it as a subview and releasing it.

If by "going back" you mean removing all subviews, then just call -removeFromSuperview from every subview and you should be fine :)

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜