保持pageControl与现实图片一致

-(void)scrollViewDidScroll:(UIScrollView *)scrollView

{

    double pageDouble = self.headerScroll.contentOffset.x/self.headerScroll.frame.size.width;

    int page = (int)(pageDouble + 0.5);

    self.pageControl.currentPage = page;

}

你可能感兴趣的:(page)