ページ化された UIScrollView のページ変更に基づいて、表示されてscrollToRowAtIndexPath:atScrollPosition:animated
いるそのページのテーブル仕様を呼び出しています。
- (void)scrollViewDidScroll:(UIScrollView *)scrollView{
CGFloat pageWidth = self.scrollView.frame.size.width;
int page = floor((self.scrollView.contentOffset.x - pageWidth/2)/pageWidth)+1;
self.pageControl.currentPage = page;
NSIndexPath *indexPath = [NSIndexPath indexPathForRow:0 inSection:page];
[self.tableView scrollToRowAtIndexPath:indexPath atScrollPosition:UITableViewScrollPositionTop animated:YES];
}
ただし、自動スクロールのアニメーションが遅すぎます。このアニメーションをよりスムーズにする方法はありますか?