NavigationViewController堆栈

时间:2017-09-06 15:27:36

标签: swift uinavigationcontroller

我担心的是NavigationViewController堆栈,因为Apple文档说明了"导航控制器对象使用导航堆栈管理当前显示的屏幕,导航堆栈由一组视图控制器表示。"那么附加到topViewController的另一个NavigationController呢?它在导航堆栈中吗?或者有两个导航堆栈? enter image description here所以最后,如果我们打电话,viewController将是这个结构的顶部       func应用程序(_ application:UIApplication,       didFinishLaunchingWithOptions launchOptions:       [UIApplicationLaunchOptionsKey:Any]?) - >布尔{

  guard let navController = window?.rootViewController as? 
  UINavigationController,
  let viewController = navController.topViewController else {
    return true
  }

0 个答案:

没有答案