+ -

重写系统黑色的TabBar

时间:2011-05-30

来源:Likwo

在手机上看
手机扫描阅读

在网络上完的时候,看倒了一个好的文章,刚好是自己感兴趣的

 

方法如下

CGRect frame = CGRectMake(0,0,320,49);
UIView *v = [UIView alloc]initWithFrame:frame];
UIImage *img = [UIImage imageNamed:@"tabbar.png"];
UIColor *c =[ [UIColor alloc]initWithPatterImage:img];
v.backgroundColor = c;
[m_TabbBar.tabBar insertSubView v atIndex:0];
m_TabBar.tabBar.opaque = YES;
[c release];
[v release];

原文地址:http://www.ieliwb.com/thanks-cocoachina-ru-developers/