Created
February 7, 2014 00:15
-
-
Save jordanekay/8855193 to your computer and use it in GitHub Desktop.
Debug -[UIScrollView setContentOffset:animated:] by changing duration
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NSTimeInterval duration = 3.0; | |
SEL selector = @selector(_setContentOffsetAnimationDuration:); | |
NSInvocation *invocation = [NSInvocation invocationWithMethodSignature:[scrollView methodSignatureForSelector:selector]]; | |
[invocation setSelector:selector]; | |
[invocation setTarget:scrollView]; | |
[invocation setArgument:&duration atIndex:2]; | |
[invocation invoke]; | |
[scrollView setContentOffset:contentOffset animated:YES] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment