码迷,mamicode.com
首页 > 移动开发 > 详细

iOS -- 全局导航栏返回键

时间:2018-07-16 14:05:21      阅读:184      评论:0      收藏:0      [点我收藏+]

标签:appear   super   处理   大小   number   child   解决   --   sel   

   [UINavigationBar appearance].backIndicatorTransitionMaskImage = [UIImage imageNamed:@"backArrowMask.png"];

    [UINavigationBar appearance].backIndicatorImage = [UIImage imageNamed:@"icon_arrowback_n”];

 

icon_arrowback_n 大小为@2x = 42* 42

 

 

自定义返回按钮会造成返回手势不能使用,解决方法
1
2
3
4
///处理自定义返回按钮后不能侧滑
@interface RootNavigationController : UINavigationController
 
@end

  

@interface RootNavigationController : UINavigationController @end @implementation RootNavigationController - (void)viewDidLoad { [super viewDidLoad]; // Do any additional setup after loading the view.  self.interactivePopGestureRecognizer.delegate = self; } - (BOOL)gestureRecognizerShouldBegin:(UIGestureRecognizer *)gestureRecognizer { if (self.childViewControllers.count == 1) { return NO; } return YES; }

iOS -- 全局导航栏返回键

标签:appear   super   处理   大小   number   child   解决   --   sel   

原文地址:https://www.cnblogs.com/shenlaiyaoshi/p/9316987.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!