I have a UIWebView that contains a lot of text content. I need to be able to get the location of the UIWebView every time it moves. I am using this code to get the point:
This is not correct. If you will use:
@implementation UIWebView(CustomScroll)
- (void) scrollViewDidScroll:(UIScrollView *)scrollView{
[self.delegate scrollViewDidScroll: scrollView];
}
@end
You will lose focus when try to enter data on page on iOS7 and more
You need to implement custom class for UIWevView and overwrite scrollViewDidScroll:
- (void) scrollViewDidScroll:(UIScrollView *)scrollView{
[super scrollViewDidScroll:scrollView];
[((id)self.delegate) scrollViewDidScroll:scrollView];
}