ios-简单集成分段选择.zip

时间:2022-07-31 13:19:24
【文件属性】:
文件名称:ios-简单集成分段选择.zip
文件大小:71KB
文件格式:ZIP
更新时间:2022-07-31 13:19:24
分段选择 SegmentViewController *vc = [[SegmentViewController alloc]init]; NSArray *titleArray = @[@"推荐", @"订阅", @"健康", @"资讯", @"原创", @"娱乐",@"搞笑",@"军事"]; vc.titleArray = titleArray; NSMutableArray *controlArray = [[NSMutableArray alloc]init]; for (int i = 0; i < vc.titleArray.count; i ) { ExampleViewController *vc = [[ExampleViewController alloc]initWithIndex:i title:titleArray]; [controlArray addObject:vc]; } vc.titleSelectedColor = [UIColor redColor]; vc.subViewControllers = controlArray; vc.buttonWidth = 80; vc.buttonHeight = ButtonHeight; [vc initSegment]; [vc addParentController:self]; 这样就把页面创建好了
【文件预览】:
SegmentView
----SegmentView.xcodeproj()
--------project.xcworkspace()
--------project.pbxproj(14KB)
--------xcuserdata()
----.git()
--------index(2KB)
--------hooks()
--------config(144B)
--------description(73B)
--------refs()
--------logs()
--------objects()
--------info()
--------COMMIT_EDITMSG(15B)
--------HEAD(23B)
----.DS_Store(6KB)
----SegmentView()
--------Assets.xcassets()
--------main.m(334B)
--------UIView+frame.m(1KB)
--------SegmentViewController.h(2KB)
--------HomepageViewController.m(2KB)
--------AppDelegate.h(277B)
--------AppDelegate.m(2KB)
--------ExampleViewController.h(298B)
--------Base.lproj()
--------SegmentViewController.m(8KB)
--------ExampleViewController.m(2KB)
--------UIView+frame.h(483B)
--------Info.plist(1KB)
--------HomepageViewController.h(229B)

网友评论