Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

对NavigationController进行了封装,效果类似天猫客户端和网易新闻客户端导航的控制器

License

Notifications You must be signed in to change notification settings

zhangfeidev/ZFNavigationController

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

3 Commits

Repository files navigation

#ZFNavigationController ##简介 很喜欢天猫和网易新闻的导航控制器的pop效果,于是封装了一个相同的pop效果。将自定义的navigationBar作为了viewcontroller的属性。第一版封装得比较简单,后期再深度封装一下。当然我只是抛砖引玉,希望喜欢这个效果的朋友们拿去自己DIY吧! ##效果 ##使用方法

首先将ZFNavigationController文件夹拖入工程中,在AppDelegate中设置你的导航控制器。

ViewController *viewVC = [[ViewController alloc] init];
ZFNavigationController *nav = [[UINavigationController alloc] initWithRootViewController:viewVC];
self.window.rootViewController = nav;
  • 开启全屏返回手势
nav.fullScreenPopGesture = YES;
  • 设置viewcontroller的title
self.title = @"首页";
  • viewcontroller隐藏navigationBar
self.navigationBarHidden = YES;

如果是storyboard,使用User Defined Runtime Attributes

博客地址:小飞的技术博客,欢迎star! ##License MIT

About

对NavigationController进行了封装,效果类似天猫客户端和网易新闻客户端导航的控制器

Resources

License

Stars

Watchers

Forks

Packages

No packages published

AltStyle によって変換されたページ (->オリジナル) /