Summary: | Click events offset in webkit-overflow-scrolling iframes | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Kris Gray <kgray> | ||||||
Component: | Layout and Rendering | Assignee: | Benjamin Poulain <benjamin> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Major | CC: | benjamin, commit-queue, jtanaka, simon.fraser | ||||||
Priority: | P2 | ||||||||
Version: | 528+ (Nightly build) | ||||||||
Hardware: | iPhone / iPad | ||||||||
OS: | Other | ||||||||
URL: | http://www.justise.com/prototype/scrolltotop.html | ||||||||
Attachments: |
|
Description
Kris Gray
2014-07-03 09:37:21 PDT
I can reproduce with WebKit ToT. It seems to be only with the old UIWebView, I cannot reproduce with WKWebView. Simon, any idea what is going on? My first suspect was the iframe but the wrong hit testing only happens when you scroll. Kris, if you get a chance, can you try the same use case with WKWebView in iOS 8? WKWebView is a new API using WebKit2, everything is brand new. It is a lot more powerful than the old UIWebView. Will try thx. Doesn't appear to reproduce on the new WKWebView. It'll take us a while to get the Salesforce app onto iOS8 though since we'll still have quite a few customers on iOS7, so this will still be an issue. So far, the WKWebView is functioning wonderfully though. Kudos. (In reply to comment #3) > Doesn't appear to reproduce on the new WKWebView. > > It'll take us a while to get the Salesforce app onto iOS8 though since we'll still have quite a few customers on iOS7, so this will still be an issue. > > So far, the WKWebView is functioning wonderfully though. Kudos. Even if someone finds the issue, that's not gonna go back to iOS 7. I suspect it is related to the WAKView hierarchy which is specific to UIWebView. I don't think fixing this for UIWebView should be high priority, our time would be better spent fixing more WKWebView issues. A few other notes that hopefully make it easier to identity and more likely to be fixed: This not only affects native and hybrid downloadable apps using UIWebview, but even oneapp home screen launchers created from within Safari. Is this the same renderer or do they share come library code? This is still evident in iOS 8.0.2 It can be reproduce in XCode 6.0.1 emulators for iOS 8. Although the clicked target element is offset by the scroll amount, the event screenX and screenY attributes seem to be correct, returning the position of the actual element, not the reacting element from lower in the page. This also affects touch and hold to select text or paste from the clipboard. If I wrap the iframe with a div styled like this, it always shows the problem: height:100%; overflow:auto; -webkit-overflow-scrolling: touch; position:relative; But if I remove one line, overflow:auto, the issues goes away. height:100%; -webkit-overflow-scrolling: touch; position:relative; Also, an earlier post mentioned that any fix wouldn't likely be backported to 7.x. At least in our testing, we have not seen the issue in anything prior to iOS 8.0. Created attachment 239082 [details]
Patch
Comment on attachment 239082 [details] Patch Clearing flags on attachment: 239082 Committed r174199: <http://trac.webkit.org/changeset/174199> All reviewed patches have been landed. Closing bug. This is great news, thanks. Is there a way to identify which iOS version will contain this fix? (In reply to comment #10) > This is great news, thanks. > > Is there a way to identify which iOS version will contain this fix? Not here, we do not discuss release plans publicly. You should contact your Apple evangelist directly to get more information. |