【发布时间】:2015-05-31 23:07:41
【问题描述】:
我一直在开发一个应用程序,它从 AppDelegate 推送一个视图控制器。当它执行时,之前在被推送的视图控制器上的导航栏消失了。现在它是一个静态导航栏(不是导航控制器的一部分),但它以前是并且仍然没有工作。我究竟做错了什么?有什么解决办法吗?
这是我用来推送它的 AppDelegate 中的代码:
var storyboard = UIStoryboard(name: "Main", bundle: nil)
var PostView: AnyObject! = storyboard.instantiateViewControllerWithIdentifier("NewView")
var rootViewController = self.window!.rootViewController as! UINavigationController
rootViewController.pushViewController(PostView as! UIViewController, animated: true)
pushViewController 是我想要推动的。
【问题讨论】:
标签: ios swift uinavigationcontroller