• <bdo id='E98Jw'></bdo><ul id='E98Jw'></ul>
    <tfoot id='E98Jw'></tfoot>

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

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

        <legend id='E98Jw'><style id='E98Jw'><dir id='E98Jw'><q id='E98Jw'></q></dir></style></legend>

        如何判断何时在 UINavigationControllerStack 中按下后退按钮

        How to tell when back button is pressed in a UINavigationControllerStack(如何判断何时在 UINavigationControllerStack 中按下后退按钮)

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

          <tfoot id='GfsGy'></tfoot>

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

                <tbody id='GfsGy'></tbody>
              <i id='GfsGy'><tr id='GfsGy'><dt id='GfsGy'><q id='GfsGy'><span id='GfsGy'><b id='GfsGy'><form id='GfsGy'><ins id='GfsGy'></ins><ul id='GfsGy'></ul><sub id='GfsGy'></sub></form><legend id='GfsGy'></legend><bdo id='GfsGy'><pre id='GfsGy'><center id='GfsGy'></center></pre></bdo></b><th id='GfsGy'></th></span></q></dt></tr></i><div id='GfsGy'><tfoot id='GfsGy'></tfoot><dl id='GfsGy'><fieldset id='GfsGy'></fieldset></dl></div>
                <bdo id='GfsGy'></bdo><ul id='GfsGy'></ul>
                  本文介绍了如何判断何时在 UINavigationControllerStack 中按下后退按钮的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  是否可以检查 UINavigationController 堆栈中何时按下后退按钮?我尝试向 self.navigationItem.backBarButtonItem 添加动作和目标,但无济于事.

                  Is it possible to check when the back button is pressed in a UINavigationController stack? I've tried adding a action and target to self.navigationItem.backBarButtonItem to no avail.

                  有人有解决办法吗?

                  推荐答案

                  你可以试试我的方法:

                  在你的 ViewController 中写入:

                  Write in your ViewController:

                  UIBarButtonItem *backBt = [[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"imageNameOfBackButton"] style:UIBarButtonItemStyleBordered target:self action:@selector(backBt_touch:)];
                  self.navigationItem.leftBarButtonItem = backBt;
                  

                  以及动作方法:

                  - (void)backBt_touch:(id)sender {
                    [self.navigationController popViewControllerAnimated:YES];
                  }
                  

                  你必须拍一张你想要的后退按钮的照片.

                  You have to take a photo of back button you want.

                  viewController弹出时隐藏后退按钮的动画和iOS的不一样!

                  Animation of hiding back button when viewController is popped is not the same animation of iOS!

                  P/s: 我已经从模拟器中得到它.希望有用!:)

                  P/s: I've get it from simulator. Hope it useful! :)

                  这篇关于如何判断何时在 UINavigationControllerStack 中按下后退按钮的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

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

                  相关文档推荐

                  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 get the previous viewcontroller that pushed my current view(如何获取推送我当前视图的上一个视图控制器)
                  The correct way to set a light status bar text color in iOS 7 based on different ViewControllers(iOS 7中基于不同ViewControllers设置灯光状态栏文字颜色的正确方法)
                  Show UITabBar when UIViewController pushed(推送 UIViewController 时显示 UITabBar)

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

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

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

                        • <tfoot id='fUnQ3'></tfoot>