分页 控制器
注意 先设置 分页数 再设置 分页颜色
-
(UIPageControl *)pageControl {
if (!_pageControl) {
_pageControl = [[UIPageControl alloc] initWithFrame:CGRectMake(0, 170, self.frame.size.width, 30)];
_pageControl.numberOfPages = _adsArray.count;
_pageControl.pageIndicatorTintColor = [UIColor grayColor];
_pageControl.currentPageIndicatorTintColor = [UIColor greenColor];_pageControl.currentPageIndicatorTintColor = KMainBodyColor;
}
return _pageControl;
}
网友评论