I am trying to move my UIScrollView to make way for the keyboard when the keyboard is shown.
What's weird is the scrollview is moving too much. I noticed that if I even just set the content offset of the scrollview to (0,0) it still moves the view down. What's bizarre, is the contentOffset of the scrollview is 0,0 before I set it! Whattt!
- (void)keyboardWasShown:(NSNotification*)notification {
NSLog(@"%f %f", scrollView.contentOffset.x, scrollView.contentOffset.x);
[scrollView setContentOffset:CGPointMake(0.0, 0.0) animated:YES];
}
This prints (0,0) but if I comment the second line, the view doesn't move. Does setContentOffset have weird secondary consequences?