1. <small id='nUf7g'></small><noframes id='nUf7g'>

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

        <tfoot id='nUf7g'></tfoot>

      1. <legend id='nUf7g'><style id='nUf7g'><dir id='nUf7g'><q id='nUf7g'></q></dir></style></legend>
      2. 禁用后退按钮并将取消按钮放在导航视图控制器中 - 就像联系人 iPhone 应用程序

        Disabling back button and put Cancel button in navigation view controller -- like contacts iPhone application(禁用后退按钮并将取消按钮放在导航视图控制器中 - 就像联系人 iPhone 应用程序)

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

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

                  <bdo id='nwGdZ'></bdo><ul id='nwGdZ'></ul>
                  <legend id='nwGdZ'><style id='nwGdZ'><dir id='nwGdZ'><q id='nwGdZ'></q></dir></style></legend>
                    <tbody id='nwGdZ'></tbody>
                  本文介绍了禁用后退按钮并将取消按钮放在导航视图控制器中 - 就像联系人 iPhone 应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  我有一个导航视图控制器,导航堆栈中有 3 个视图控制器.现在在第三个也是最可见的视图控制器上,我有一个默认的后退按钮.

                  I have a navigation view controller and there are 3 view controllers in the navigation stack. Now on the third and top most visible view controller I have a default back button coming in.

                  我需要将这个视图控制器带入我所做的编辑模式...现在要求有一个取消按钮作为左栏按钮项而不是后退按钮.

                  I need to bring this view controller in edit mode which I did... Now the requirement is to have a cancel button as the left bar button item instead of back button.

                  这类似于 iPhone 的联系人应用程序提供的功能,您可以在其中编辑特定联系人.

                  This is similar to the functionality given by contacts application of iPhone where you edit a particular contact.

                  任何线索如何实现这一点?

                  Any clue how to achieve this?

                  推荐答案

                  要隐藏后退按钮并添加左栏按钮使用-

                  To hide back button and add a left bar button use-

                  [self.navigationItem setHidesBackButton:TRUE];
                  
                      UIBarButtonItem *leftBarButton = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemCancel target:self action:@selector()];
                      [self.navigationItem setLeftBarButtonItem:leftBarButton];
                      [leftBarButton release];
                  

                  然后以编程方式返回到上一个视图控制器,您可以这样做-

                  And then to programmatically return to the previous view controller, you can do-

                  [self.navigationController popViewControllerAnimated:YES];
                  

                  这篇关于禁用后退按钮并将取消按钮放在导航视图控制器中 - 就像联系人 iPhone 应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

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

                  相关文档推荐

                  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)

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

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

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