<i id='zjDbC'><tr id='zjDbC'><dt id='zjDbC'><q id='zjDbC'><span id='zjDbC'><b id='zjDbC'><form id='zjDbC'><ins id='zjDbC'></ins><ul id='zjDbC'></ul><sub id='zjDbC'></sub></form><legend id='zjDbC'></legend><bdo id='zjDbC'><pre id='zjDbC'><center id='zjDbC'></center></pre></bdo></b><th id='zjDbC'></th></span></q></dt></tr></i><div id='zjDbC'><tfoot id='zjDbC'></tfoot><dl id='zjDbC'><fieldset id='zjDbC'></fieldset></dl></div>
    <tfoot id='zjDbC'></tfoot>

    <small id='zjDbC'></small><noframes id='zjDbC'>

  1. <legend id='zjDbC'><style id='zjDbC'><dir id='zjDbC'><q id='zjDbC'></q></dir></style></legend>

        <bdo id='zjDbC'></bdo><ul id='zjDbC'></ul>

    1. 不能在 Swift 中关闭导航控制器

      Can#39;t dismiss navigation controller in Swift(不能在 Swift 中关闭导航控制器)

      • <legend id='gFjqF'><style id='gFjqF'><dir id='gFjqF'><q id='gFjqF'></q></dir></style></legend>

        <small id='gFjqF'></small><noframes id='gFjqF'>

        <i id='gFjqF'><tr id='gFjqF'><dt id='gFjqF'><q id='gFjqF'><span id='gFjqF'><b id='gFjqF'><form id='gFjqF'><ins id='gFjqF'></ins><ul id='gFjqF'></ul><sub id='gFjqF'></sub></form><legend id='gFjqF'></legend><bdo id='gFjqF'><pre id='gFjqF'><center id='gFjqF'></center></pre></bdo></b><th id='gFjqF'></th></span></q></dt></tr></i><div id='gFjqF'><tfoot id='gFjqF'></tfoot><dl id='gFjqF'><fieldset id='gFjqF'></fieldset></dl></div>
          <tbody id='gFjqF'></tbody>
          <tfoot id='gFjqF'></tfoot>

              <bdo id='gFjqF'></bdo><ul id='gFjqF'></ul>
                本文介绍了不能在 Swift 中关闭导航控制器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                问题描述

                所以我有一个简单的导航控制器,带有一个注册,点击完成,然后你转到主页.问题是当您转到主页时,导航控制器随之而来.

                So I have a simple navigation controller with a sign up, hit done and you go to the home page. The problem is when you go to the home page, the navigation controller follows.

                正如您在最后一张图片(主页)中看到的那样,导航栏仍然存在.当用户在第一张图片上按下完成"时,我使用 self.performSegueWithIdentifier("loginTrue", sender: nil) 转到主页".我试过使用

                As you can see in the last picture (home page), the navigation bar remains. When the user presses "Done" on the first image I use self.performSegueWithIdentifier("loginTrue", sender: nil) to go to the "home page". I've tried using

                self.presentingViewController?.dismissViewControllerAnimated(true, completion: nil)
                

                但似乎什么也没发生.所以总结一下,关于如何从主页"关闭"导航控制器的任何想法?谢谢!

                But nothing seems to happen. So to wrap it all up, any idea on how I can "dismiss" the navigation controller from the "home page"? Thanks!

                推荐答案

                试试

                self.navigationController?.popViewControllerAnimated(true)
                

                更新:Swift 4.2

                self.navigationController?.popViewController(animated: true)
                

                这篇关于不能在 Swift 中关闭导航控制器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                相关文档推荐

                UINavigationController inside a UITabBarController inside a UISplitViewController presented modally on iPhone(UISplitViewController 内的 UITabBarController 内的 UINavigationController 以模态方式呈现在 iPhone 上) - IT屋-程序员软件开发技术分
                ViewController in UINavigationController orientation change(UINavigationController 中的 ViewController 方向更改)
                Custom back button in UINavigationController(UINavigationController 中的自定义后退按钮)
                How to add a navigation controller programmatically in code but not as initial view controller(如何在代码中以编程方式添加导航控制器,但不作为初始视图控制器)
                The correct way to set a light status bar text color in iOS 7 based on different ViewControllers(iOS 7中基于不同ViewControllers设置灯光状态栏文字颜色的正确方法)
                View being blocked by UITransitionView after being presented(呈现后被 UITransitionView 阻止的视图)
              1. <small id='dSZcz'></small><noframes id='dSZcz'>

                    <tbody id='dSZcz'></tbody>
                1. <tfoot id='dSZcz'></tfoot>
                  • <i id='dSZcz'><tr id='dSZcz'><dt id='dSZcz'><q id='dSZcz'><span id='dSZcz'><b id='dSZcz'><form id='dSZcz'><ins id='dSZcz'></ins><ul id='dSZcz'></ul><sub id='dSZcz'></sub></form><legend id='dSZcz'></legend><bdo id='dSZcz'><pre id='dSZcz'><center id='dSZcz'></center></pre></bdo></b><th id='dSZcz'></th></span></q></dt></tr></i><div id='dSZcz'><tfoot id='dSZcz'></tfoot><dl id='dSZcz'><fieldset id='dSZcz'></fieldset></dl></div>

                        <legend id='dSZcz'><style id='dSZcz'><dir id='dSZcz'><q id='dSZcz'></q></dir></style></legend>
                          <bdo id='dSZcz'></bdo><ul id='dSZcz'></ul>