【发布时间】:2012-09-13 06:01:27
【问题描述】:
我在管理多个UINavigationControlller 时遇到问题。
我有一个UITabBar,在每个标签中我都有一个单独的UINavigationController。所以如果我通过
UITabBar
tabBar.selectedIndex = i; // where i is index of tabbar.
当我返回上一个标签时
tabBar.selectedIndex = previousIndex;
我转到UINavigationController 的根目录,而不是我之前离开的视图控制器。
我想转到视图控制器,从该控制器跳转到另一个选项卡,而不调用 -viewDidLoad: 或 -viewWillAppear:。
我需要一个显示UINavigationController 或我的viewController 的方法。
【问题讨论】:
-
这是 UITabBar 的默认功能,除非我们对显示 rootView 进行任何更改...你可能会在 tabBarDelegate 中写一些东西来显示 rootView..
-
您是否使用this 的任何tabbarDelegate 方法,请分享代码
-
好的,我正在检查我的 tabbardelegate。 @vishy
标签: iphone ios xcode uinavigationcontroller uitabbarcontroller