UIWebView ignoring contentInset on double tap

Originator:matt.toohey
Number:rdar://17698873 Date Originated:
Status:Open Resolved:
Product:iOS Product Version:7.1.2
Classification: Reproducible:YES
 
Summary:
Double tapping on content in a UIWebView should scroll/zoom to make that content visible. If the webview's scroll view has a content inset, then the web view gets confused. The content the user tapped on actually scrolls to the absolute top of the web view, rather than taking the content inset into account.

This is bad for the user, as if the web view is partially behind a navigation bar (or similar) then the content they double tap appears behind the navigation bar.

Steps to Reproduce:
1: Launch app from the WebViewInset zip file
2: Double tap content in the webview

In the attached zip, "WebViewInset.mov" shows the bug

Expected Results:
Content should be within visible part of the webview (i.e. within content insets)
In this specific case I would expect the content to stay still

Actual Results:
Content moves out of sight, above the content inset

Version:
iOS 7.1.2

Notes:


Configuration:
iPhone 5s, AT&T 64 GBWebViewInset.zip - configuration file has been successfully uploaded.

Attachments:
'WebViewInset.zip' was successfully uploaded.

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!