#import "ViewController.h"
#import "AMPageView.h"
@interface ViewController ()<UIScrollViewDelegate>
@property (weak, nonatomic) IBOutlet UIScrollView *UIScroll;
@property (assign, nonatomic)int startX;
@property (assign, nonatomic)int endX;
@property (weak, nonatomic) IBOutlet UIPageControl *PageC;
@end
@implementation ViewController
- (void)viewDidLoad {
[super viewDidLoad];
//新建XIB
AMPageView *pageView1=[AMPageView pageView];
pageView1.frame=CGRectMake(39, 120, 320, 130);
//设置点颜色
pageView1.currentColor=[UIColor greenColor];
pageView1.otherColor=[UIColor redColor];
pageView1.imgName=@[@"img_00",@"img_01",@"img_02",@"img_03",@"img_04"];
[self.view addSubview:pageView1];
}
- (void)didReceiveMemoryWarning {
[super didReceiveMemoryWarning];
}
@end
文件下载:
http://download.csdn.net/detail/z2340868/9581477