3

I have a simple UIScrollView and a UIPager, whenever I scroll through the scrollview I want to change my pager, but for some reason (void)scrollViewDidEndScrollingAnimation:(UIScrollView *)scrollView isn't being called.

My delegate is working since (void)scrollViewDidScroll:(UIScrollView *)scrollView just works, am I forgetting something here?

Or is there another way you can change a UIPager when the scrollview is being scrolled through?

janusfidel
  • 8,036
  • 4
  • 30
  • 53
woutr_be
  • 9,532
  • 24
  • 79
  • 129

2 Answers2

6

http://developer.apple.com/library/ios/#DOCUMENTATION/UIKit/Reference/UIScrollViewDelegate_Protocol/Reference/UIScrollViewDelegate.html

The scroll view calls this method at the end of its implementations of the UIScrollView and setContentOffset:animated: and scrollRectToVisible:animated: methods, but only if animations are requested.

The following two methods call will only work. must be animated value is YES.

[myScrollView setContentOffset:<#(CGPoint)#> animated:YES];
[myScrollView scrollRectToVisible:<#(CGRect)#> animated:YES];
Community
  • 1
  • 1
bitmapdata.com
  • 9,572
  • 5
  • 35
  • 43
1

I've had mistaken (void)scrollViewDidEndDecelerating:(UIScrollView *)scrollView and (void)scrollViewDidEndScrollingAnimation:(UIScrollView *)scrollView.

UIScroll View Delegate not calling ScrollViewDidEndScrollingAnimation

Community
  • 1
  • 1
woutr_be
  • 9,532
  • 24
  • 79
  • 129