【发布时间】:2015-05-30 11:33:58
【问题描述】:
我有一个UIViewController (a),它是UINavigationController (b) 中的根视图控制器。 UINavigationController 以模态方式显示(通过 segue)与另一个完全分开的 UIViewController (c)。
我遇到的问题是,当我尝试关闭模态显示的 vc (a) 时,我得到一个黑屏,没有显示任何内容。我本来希望看到 (c) 显示出来。
我应该解雇 (a) 的正确方法是什么,它存在于 (b) 中,以便 (c) 之后正确可见?
到目前为止,我已经尝试了以下方法,但都没有奏效:
self.dismissViewControllerAnimated(true, completion: nil);
self.navigationController!.dismissViewControllerAnimated(true, completion: nil);
self.presentingViewController?.dismissViewControllerAnimated(true, completion: nil);
【问题讨论】:
标签: ios swift uiviewcontroller uinavigationcontroller modalviewcontroller