<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    Sealyu

    --- 博客已遷移至: http://www.sealyu.com/blog

      BlogJava :: 首頁 :: 新隨筆 :: 聯系 :: 聚合  :: 管理 ::
      618 隨筆 :: 87 文章 :: 225 評論 :: 0 Trackbacks

    Yes! There is a way of using the backBarButton with a custom action. No, it’s not by overriding the backBarButton property of navigationItem. This is not an ugly solution with images that simulate the “Back”-button (arrow-shaped.) It’s possible to use the backBarButton for popping the current viewController as normal, but than with other animations such as UIViewAnimationTransitionCurlDown.

    Enough said, the solution is simple. You have to subclass your navigationController’s  popViewControllerAnimated:(BOOL)animated. So create a custom navigationController:

    customNavigationController.h

    #import
    @interface customNavigationController : UINavigationController {}
    @end

    And a custom “popViewControllerAnimated:(BOOL)animated”, this popViewControllerAnimated-function uses the “UIViewAnimationTransitionCurlDown” when popping from a SettingsTableView.

    customNavigationController.m

    #import "customNavigationController.h"
    #import "SettingsTableController.h"
     
    @implementation customNavigationController
     
    - (UIViewController *)popViewControllerAnimated:(BOOL)animated
    {
    if([[self.viewControllers lastObject] class] == [SettingsTableController class]){
     
    [UIView beginAnimations:nil context:NULL];
    [UIView setAnimationDuration: 1.00];
    [UIView setAnimationTransition:UIViewAnimationTransitionCurlDown
    forView:self.view cache:NO];
     
    UIViewController *viewController = [super popViewControllerAnimated:NO];
     
    [UIView commitAnimations];
     
    return viewController;
    } else {
    return [super popViewControllerAnimated:animated];
    }
    }
    @end

    Use your custom navigationController in your appDelegate:

    customNavigationController *navigationController =
    [[customNavigationController alloc]
    initWithRootViewController:rootView];

    posted on 2010-11-13 23:12 seal 閱讀(621) 評論(0)  編輯  收藏 所屬分類: iPhone
    主站蜘蛛池模板: 野花视频在线官网免费1| 亚洲成人免费在线观看| 污网站免费在线观看| 成人午夜性A级毛片免费| 亚洲第一精品电影网| 午夜精品免费在线观看| 亚洲电影免费在线观看| 老汉精品免费AV在线播放| 亚洲国产精品久久久久网站| 99爱在线精品视频免费观看9| 亚洲一区二区影院| 永久免费毛片在线播放| 在线综合亚洲中文精品| 韩国二级毛片免费播放| 久久久久亚洲国产AV麻豆| yy6080亚洲一级理论| 中文字幕a∨在线乱码免费看| 亚洲精品无码专区久久久| 午夜免费啪视频在线观看 | 又黄又爽的视频免费看| 日本激情猛烈在线看免费观看| 久久亚洲AV无码西西人体| 在线涩涩免费观看国产精品 | 免费A级毛片无码A∨免费| 亚洲1区1区3区4区产品乱码芒果 | 亚洲一线产品二线产品| 亚洲AV永久无码精品一区二区国产| 一级美国片免费看| 久久久久久亚洲精品| 免费可以在线看A∨网站| 暖暖免费中文在线日本| 亚洲精品在线不卡| 国产片免费福利片永久| 免费视频一区二区| 中文有码亚洲制服av片| 久久久久国产成人精品亚洲午夜| 无码专区AAAAAA免费视频| 亚洲中文字幕无码av永久| 亚洲精品无码MV在线观看| 美女被免费喷白浆视频| 久久久WWW成人免费精品|