在iPhone中显示/隐藏TabBarController [英] Show/Hide TabBarController in iphone
问题描述
我正在iphone中制作应用程序,其中我有4个tabbars&在其中一个选项卡中,我在第二个视图中有4个视图,它需要隐藏标签栏。我可以使用正在推送的Viewcontroller的initWithNib方法中的setHidesBottomBarWhenPushed:YES来隐藏标签栏。但是当导航到屏幕3时,使用否调用相同的方法不会使标签栏出现。任何想法?
i am making an application in iphone in which i have 4 tabbars & in one of its tab i have 4 views in 2nd view it needs to hide the tab bar. I am able to hide the tab bar using the setHidesBottomBarWhenPushed:YES in in the initWithNib method of the Viewcontroller being pushed. But when navigating to the screen 3 , calling the same method with "NO" does not make the tab bar appear. any ideas?
推荐答案
John Smith是正确的。该示例的网址为: http://developer.apple.com/ iphone / library / samplecode / TheElements / index.html
John Smith is correct. The URL for that sample is: http://developer.apple.com/iphone/library/samplecode/TheElements/index.html
执行此操作的代码位于AtomicElementViewController.m中,实现此效果的行是init方法:
The code that does this is in AtomicElementViewController.m, and the line that achieves this effect is in the init method:
self.hidesBottomBarWhenPushed = YES;
这篇关于在iPhone中显示/隐藏TabBarController的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!