我有这个错误,我不明白,它是让我的头受伤。所以,基本上,在我的iPhone应用程序中,我有UITabBar,每个标签中都有UINavigationControllers。Iphone应用程序崩溃时弹出到UITabBar标签的rootController
事情是这样的:
someViewController *someController = [[someViewController alloc] myInit];
UINavigationController *someNav = [[UINavigationController alloc] initWithRootViewController:someController];
tab = [[UITabBarController alloc] init];
tab.viewControllers = [NSArray arrayWithObjects:otherNav, otherNav, evilNav, nil];
[window addSubview:tab.view];
所以重现我的“珍贵”的错误我是这样的:
click evilNav tab
-> push tableListView (category list)
-> push otherTableListView (category items list)
-> push someOtherView (single item)
-> popToRoot || popToController withindex:0 || click on evilNav tab again || pop to otherTableListView -> pop to tableListView
-> crash (with no notable error)
所以,如果我走这么远来someOtherView我不能回去第一个tableListView(rootViewController)没有应用程序崩溃。同时,我可以转到其他选项卡,然后甚至在不崩溃的情况下单击evilNav(处于其他桌面视图或其他视图状态时)。
什么可能导致此问题? (如果您需要,我会发布更多代码)
太感谢你了!评论发布的工作如同魅力,我的应用程序不再崩溃。不知道究竟是什么错误.. 再次感谢! – sniurkst 2009-08-13 18:45:43