- 博客(1)
- 资源 (5)
- 收藏
- 关注
自定义开关按钮(ios)
可以设置开关的颜色,修改字符串等。例如,用图片代替:UIImage *normal_left = [[UIImage alloc] initWithContentsOfFile:[[NSBundle mainBundle] pathForResource:@"left_normal" ofType:@"png"]];
UIImage *normal_right = [[UIImage alloc] initWithContentsOfFile:[[NSBundle mainBundle] pathForResource:@"right_normal" ofType:@"png"]];
NSMutableArray *unselectImages = [[NSMutableArray alloc]initWithObjects:normal_left, normal_right, nil];
[normal_left release];
[normal_right release];
UIImage *select_left = [[UIImage alloc] initWithContentsOfFile:[[NSBundle mainBundle] pathForResource:@"left_press" ofType:@"png"]];
UIImage *select_right = [[UIImage alloc] initWithContentsOfFile:[[NSBundle mainBundle] pathForResource:@"right_press" ofType:@"png"]];
NSMutableArray *selectImages = [[NSMutableArray alloc]initWithObjects: select_left, select_right, nil];
[select_left release];
[select_right release];
CQSegmentControl *_segmentedControl= [[CQSegmentControl alloc] initWithItemsAndStype:titleItems stype:TitleAndImageSegmented];
for (UIView *subView in _segmentedControl.subviews)
{
[subView removeFromSuperview];
}
_segmentedControl.normalImageItems = unselectImages;
[unselectImages release];
_segmentedControl.highlightImageItems = selectImages;
2012-05-30
linux试题 软件工程课件群
我们这学期上linux教程(第二版),看这本书看的真郁闷,在最后的关头找到了网上的部分试卷,里面很多有用而且可能考到的命令,因为本人时间不足,没有充分珍惜这些资料。借此,大家共享一下
2009-06-28
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅
299