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YI+2rgOCS9cXzlPJNSwtLA45hMWjeDBrYiGbdKUhnnsC2GhAg2QQAPQJXDNj5Jnj3vmQvQR0Ro9XHeeu3MEt952e7EspTM6KJ598sovRPo6gWks2vMirHTqb/OnyMEtgZM6HZ0E+6x3WrkKXF1aHcokLk3VYnMojLC1qnPLgGJbHTY9KE8zjr8tDAitXrpSqudPm/uTjI4dk6njjXB5zyAXsY66K1eQB9zhClAcvjnKCPM5VucF69MXrKLINowmLQz7B+OB1GE1QrmF5sqEJ5vHXfVsCzz33nJ1BV5ipXdff/PwX0tR+xk7vmOJhe8Wn+bHHHrPTcmxOZGBqftddd9lFm4TNO2HP5hwg12PwnOvgD/FqnJ6HHd04zoMBHj54CeRTAnGBbBQ+bjsypXfzFvM5JlJ2SsXkgS2bdyuCR2zdmHVnzJiRsims/7C2FQxvNidi5kwWcc+DdO51kA75B+OU3r03nG/ablLMca5x5Nu03XiUmb95U8+a16DRH7Z8tvXQa9a2gudr1661i7uk6Y8PoC9btkxWrVplP4hOPAorvxUrVsg999xj1xExzWGhqIbpw3/6U/n+zx6UOY0N1lsFOx+LNNj/7r77bpv5vvvuk8cff9y+josZR4HcBXkFa01zrxGKXutRBcW1pgfjgvFh15pHj8pPr/3RSyAfEuDZSRfioklXDulRyorCJ980rK2xNsMaGM4MeJQFjwAXdOk82VjzCaOp353AlOHDK8Q9T9Y2ZDdwTyLPiBFn76vmHTGi59YOrqw5d+nqdyVMzJqHdPfH2ghri24c7XWvkYfSKLhrnB41niNOKKyPAfSseRH3/zeBrfUZL/VPAAAAAElFTkSuQmCC" alt="" />
实现对应的思路有:
1.首先你要拥有这样的一个控件CSTabBar,继承自tabbar,这样才能做到重构(废话)
2.你要在使用CSTabBar使用kvc来实现 [self setValue:newTab forKey:@"tabBar"]; newTab是自己设定的对应的tabbar
3.就可以开始构造自己的Tabbar了,构造的第一步当然是设置中间按钮的size。
4.改变对应的tabbar 里面item的大小,和对应点击事件发生的时候你要响应什么东西。
//
// CSTabBar.m
// diary
//
// Created by asheng123 on 15/4/11.
// Copyright (c) 2015年 asheng123. All rights reserved.
// #import "CSTabBar.h"
@interface CSTabBar()
@property(nonatomic,weak)UIButton *plusButton;
@end
@implementation CSTabBar -(instancetype)initWithFrame:(CGRect)frame
{
if (self = [super initWithFrame:frame]) {
[self setPlusButton];
}
return self;
}
-(void)setPlusButton
{
UIButton * plusButton=[[UIButton alloc]init];
[plusButton setBackgroundImage:[UIImage imageNamed:@"tabbar_compose_button"] forState:UIControlStateNormal];
[plusButton setBackgroundImage:[UIImage imageNamed:@"tabbar_compose_button_highlighted"] forState:UIControlStateHighlighted];
[plusButton setImage:[UIImage imageNamed:@"tabbar_compose_icon_add"] forState:UIControlStateNormal];
[plusButton setImage:[UIImage imageNamed:@"tabbar_compose_icon_add_highlighted"] forState:UIControlStateHighlighted];
[self addSubview:plusButton];
self.plusButton = plusButton;
}
-(void)layoutSubviews
{
[super layoutSubviews]; [self setupPlusButtonFrame];
[self setupallTabBarFrame];
}
-(void)setupPlusButtonFrame
{
self.plusButton.size = self.plusButton.currentBackgroundImage.size;
self.plusButton.center = CGPointMake(self.width*0.5, self.height*0.5);
}
-(void)setupallTabBarFrame
{
int index= ;
for (UIView *tabBarButton in self.subviews) {
// [tabBarButton isKindOfClassL: NSClassFromString(@"UITabBarButton")];
BOOL isTabBar =[tabBarButton isKindOfClass:NSClassFromString(@"UITabBarButton")];
if (!isTabBar) {
continue;
}
[self setTabBarButtonFrame:tabBarButton withIndex:index];
[self setTabBarButtonTextColor:tabBarButton withIndex:index]; index++;
} }
//设置每一个tabbar对应的frame
//传进来的tabbar 也就是当前的一个按钮,那么要给他设定对应的值
-(void)setTabBarButtonFrame:(UIView *)tabBar withIndex:(int)index
{
//首先取大小
CGFloat tabWidth= self.width/(self.items.count +);
CGFloat tabHeight = self.height; //然后就是给对应控件赋值了
if (index>=) {
tabBar.frame = CGRectMake(tabWidth*(index +), , tabWidth, tabHeight);
}else
{
tabBar.frame = CGRectMake(tabWidth *index, , tabWidth, tabHeight);
} }
//设置每一个tabbar对应的背景color
-(void)setTabBarButtonTextColor:(UIView *)tabBar withIndex:(int)index
{
//要给每一个选中的tabbar对应一个background
//比较重要的就是判断对应的index和当前选中的项目是不是相同
int currentSelect= (int)[self.items indexOfObject:self.selectedItem];
//判断对应的是不是选中的项
for (UILabel *label in tabBar.subviews) {
if (![label isKindOfClass:NSClassFromString(@"UILabel")]) {
continue;
}
if (currentSelect == index) {
label.textColor = [UIColor orangeColor];
}else
{
label.textColor = [UIColor blackColor];
}
}
}
@end
其中index这个设计的比较巧妙。通过遍历来找到对应的index,判断是否是相同的一个属性,isKindOfClass可以判断,因为这个事对应的子类中的方法,可以判断出是什么调用了这个方法。之间存在着继承关系
封装实现一个自己的tabbar的更多相关文章
- 自己封装的一个LoadRes组件
这两周一直太忙,没有好好处理上上上周遇到的一个让我加班到凌晨的问题,这个问题是判断flash的加载. 之前的思路是让flash的人在制作flash的时候,加入了一个回调方法,该方法再会回调我页面的方法 ...
- 自己封装的一个JS分享组件
因为工作的需求之前也封装过一个JS分享插件,集成了我们公司常用的几个分享平台. 但是总感觉之前的结构上很不理想,样式,行为揉成一起,心里想的做的完美,实际上总是很多的偏差,所以这次我对其进行了改版. ...
- 使用原生JS实现一个风箱式的demo,并封装了一个运动框架
声明,该DEMO依托于某个培训机构中,非常感谢这个培训结构.话不多说,现在开始改demo的制作. 首先,在前端的学习过程中,轮播图是我们一定要学习的,所以为了更加高效的实现各种轮播图,封装了一个运动的 ...
- 使用 ViewPager 和 RadioGroup 封装的一个导航控件
import android.animation.ObjectAnimator; import android.content.Context; import android.graphics.dra ...
- 在jsp提交表单的参数封装到一个方法里
建议去看一下孤傲苍狼写的Servlet+JSP+JavaBean开发模式(http://www.cnblogs.com/xdp-gacl/p/3902537.html), 最好把他JavaWeb学习总 ...
- 自己封装的一个js方法用于获取显示的星期和日期时间
自己封装的一个js方法用于获取显示的星期和日期时间 /** * 获取用于显示的星期和日期时间 * @param date * @returns {string} */ function getWeek ...
- 基于Dapper二次封装了一个易用的ORM工具类:SqlDapperUtil
基于Dapper二次封装了一个易用的ORM工具类:SqlDapperUtil,把日常能用到的各种CRUD都进行了简化封装,让普通程序员只需关注业务即可,因为非常简单,故直接贴源代码,大家若需使用可以直 ...
- Timber(对Log类封装的一个工具)
Timber(对Log类封装的一个工具) https://blog.csdn.net/hzl9966/article/details/51314137 https://www.jianshu.com/ ...
- SpringMVC 中,当前台传入多个参数时,可将参数封装成一个bean类
在实际业务场景中,当前台通过 url 向后台传送多个参数时,可以将参数封装成一个bean类,在bean类中对各个参数进行非空,默认值等的设置. 前台 url ,想后台传送两个参数,userName 和 ...
随机推荐
- hdu 1032
题目的意思是把输入的i,j 从i到j的每一个数 做循环,输出循环次数最大的值 易错的地方:做循环是容易直接用i进行计算 i=i/2:或i=i*3+1: 这样i的值改变就不能在做下面数的循环 #incl ...
- iOS开发UI篇—常见的项目文件介绍
iOS开发UI篇—常见的项目文件介绍 一.项目文件结构示意图 二.文件介绍 1.products文件夹:主要用于mac电脑开发的可执行文件,ios开发用不到这个文件 2.frameworks文件夹主要 ...
- html基本标签结构
简单的html5的基本架构 HTML全称为HyperText Markup Language,一款写给浏览器的语言. HyperText:超文本(文本,图片,视频,音频,链接) Markup Lanu ...
- JavaScript 语句
JavaScript 语句 JavaScript 语句向浏览器发出的命令.语句的作用是告诉浏览器该做什么. JavaScript 语句 JavaScript 语句是发给浏览器的命令. 这些命令的作用是 ...
- hdu 1053 (huffman coding, greedy algorithm, std::partition, std::priority_queue ) 分类: hdoj 2015-06-18 19:11 22人阅读 评论(0) 收藏
huffman coding, greedy algorithm. std::priority_queue, std::partition, when i use the three commente ...
- OC 解决NSArray、NSDictionary直接打印中文出现乱码的问题
在iOS开发中,经常需要查看数组中得元素是否是自己想要的,但是苹果并没有对直接打印数组中得中文作处理,直接打印就会出现一堆很讨厌的东西,解决其实很简单,就是需要通过为NSArray添加分类,重写 - ...
- [转]概率基础和R语言
概率基础和R语言 R的极客理想系列文章,涵盖了R的思想,使用,工具,创新等的一系列要点,以我个人的学习和体验去诠释R的强大. R语言作为统计学一门语言,一直在小众领域闪耀着光芒.直到大数据的爆发,R语 ...
- Android 学习第11课,android 实现拨打电话的功能
1. 先布局界面,界面采用线性垂直方式来布局 在layout 界面文件中 activity_main.xml 中 <LinearLayout xmlns:android="http:/ ...
- 诺基亚XL中Intent.ACTION_VIEW无效的问题
今天测试播放视频的时候,发现在诺基亚XL机型里不能弹出视频应用列表. 我的代码是: Intent intent = new Intent(Intent.ACTION_VIEW); intent.set ...
- 关于在win7内集成usb3.0驱动。
mac air 装了win7但是折腾良久还是无法升级,只能是重新安装. 很蛋疼.bootcamp 老是找不到驱动.只能是手动分区后U盘引导安装. 驱动的下载,直接在Os x 下用bootcamp 下载 ...