开发者

how to display a a tabbar on a page without calling it in appdelegate

I want to display tabbar with tabbaritems on a page. But the main problem is that I don't want the the tabbarcontroller to be called from delegate class. So how is this possi开发者_Python百科ble. Thanks !!!


Inside your .h file

IBOutlet UITabBarController *tabbarcontroller;
@property(nonatomic,retain) UITabBarController *tabbarcontroller;

in your .m file

[self.view addSubview:tabbarcontroller.view];


You just create and add a UITabBar as a subview of your chosen view. You don't need a UITabBarController to have a tabbar, and even if you do you can add that view to an existing view controller, rather than having it in your delegate.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜