UINavigationController的理解
来源:互联网 发布:淘宝商品摄影教程 编辑:程序博客网 时间:2024/06/06 01:11
UINavigationController是iOS中最常见的viewcontroller,也是管理viewcontroller比较方便的一个容器,也可以理解是一个栈,先进后出,所以开始创建工程的时候一般会初始化一个容器栈。push进栈 pop出栈。
/配置rootUI
-(void)configBaseTabRootVCUI
{
NSLog(@"%@",NSStringFromSelector(_cmd));
//第一个nav
self.firstVC.tabBarItem = [selfcreateTabBarItemWithTitle:@"首页"imageName:@"HomeTabPage.png"selectedImageName:@"HomeTabPageLight.png"];
self.firstVC.tabBarItem.tag =tabBarItem_tag + 0;
[selfsetFontAndColorForTabBarItem:self.firstVC.tabBarItem];
//第二个nav
self.secondVC.tabBarItem = [selfcreateTabBarItemWithTitle:@"服务"imageName:@"ServerTab.png"selectedImageName:@"ServerTabLight.png"];
self.secondVC.tabBarItem.tag =tabBarItem_tag + 1;
[selfsetFontAndColorForTabBarItem:self.secondVC.tabBarItem];
//第三个nav
self.thirdVC.tabBarItem = [selfcreateTabBarItemWithTitle:@"附近"imageName:@"FindTab.png"selectedImageName:@"FindTabLight.png"];
self.thirdVC.tabBarItem.tag =tabBarItem_tag + 2;
[selfsetFontAndColorForTabBarItem:self.thirdVC.tabBarItem];
//第四个nav
self.fourthVC.tabBarItem = [selfcreateTabBarItemWithTitle:@"我的"imageName:@"MineTab.png"selectedImageName:@"MineTabLight.png"];
self.fourthVC.tabBarItem.tag =tabBarItem_tag + 3;
[selfsetFontAndColorForTabBarItem:self.fourthVC.tabBarItem];
//设置TabBar背景
UIImage* tabBarShadow = [UIImageimageNamed:@"clear.png"];//需要的图片
[[UITabBarappearance]setBackgroundImage:tabBarShadow];
self.tabBar.backgroundColor = [UIColorwhiteColor];
self.viewControllers =@[self.firstVC,self.secondVC,self.thirdVC,self.fourthVC];
}
-(BaseFirstViewController*)firstVC
{
if (!_firstVC) {
_firstVC = [[BaseFirstViewControlleralloc]init];
}
return_firstVC;
}
- UINavigationController的理解
- 分析总结iOS中UINavigationController的理解
- 对Viewcontroller在UINavigationController中入栈出栈的理解
- 初学者快速理解UINavigationController结构
- UINavigationController的使用
- UINavigationController的使用技巧
- UINavigationController的用法
- UINavigationController的popViewControllerAnimated问题
- UINavigationController的popViewControllerAnimated问题
- UINavigationController之间的推进
- UINavigationController的popViewControllerAnimated问题
- UINavigationController的一些总结
- UINavigationController的popViewControllerAnimated问题
- UINavigationController的popViewControllerAnimated 问题
- UINavigationController的使用
- UINavigationController的popViewControllerAnimated问题
- UINavigationController的视图切换
- UINavigationController 的 pushViewController不起作用
- 前后端分离 ie上传文件兼容
- 极好的博弈论文章
- 电商网站一般用什么技术开发
- Sentry Robots UVA
- LX
- UINavigationController的理解
- yield函数测试
- oracle数据库及mysql数据库分页
- Android6.0动态权限解决方法
- 安卓画笔实现的探索
- Android Studio 开发NDK项目生成.h文件方法
- flyerinternational内幕看了才懂这行水太深
- 获取微信用户openid的三种方法#ACCESS_TOKEN
- nginx http请求转https