Finishing up a navigation transition in an unexpected state

{app.params.name}} {app.params.name}} {app.params.name}}

我在做我的ios应用中,遇到了这样的情况:错误代码如下:

2013-05-13 21:46:47.985 xunYi4[31694:c07] nested pop animation can result in corrupted navigation bar
2013-05-13 21:46:48.336 xunYi4[31694:c07] Finishing up a navigation transition in an unexpected state. Navigation Bar subview tree might get corrupted.
2013-05-13 21:46:48.337 xunYi4[31694:c07] Unbalanced calls to begin/end appearance transitions for <personViewController: 0x75a01b0>.
使得我的运行的结果是,在调用pushViewConroller的时候出现了两次push,导致程序不能达到自己想要的效果,于是查找资料,最终我的解决方案是:如下:

personViewController *person = [[personViewController alloc] initWithNibName:@"personViewController" bundle:nil];
[self.navigationController popToRootViewControllerAnimated:NO];
person.navigationItem.title = button.titleLabel.text;
[self.navigationController pushViewController:person animated:YES];
达到了我要的效果,但是问题是这个报错的信息还是存在,请求高手给予指点


版权声明

davidzhang 创作并维护的 Gowhich 博客采用 创作共用保留署名-非商业-禁止演绎4.0国际许可证。

本文首发于 Gowhich 博客( https://www.gowhich.com ),版权所有,侵权必究。

本文永久链接: https://www.gowhich.com/blog/124

comments powered by Disqus