WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
Bug 150168
Scrolling iframe inside scrollable div does not work with trackpad
https://bugs.webkit.org/show_bug.cgi?id=150168
Summary
Scrolling iframe inside scrollable div does not work with trackpad
Anders Johansson
Reported
2015-10-15 06:52:36 PDT
Created
attachment 263154
[details]
Testcase source Open
http://output.jsbin.com/zetevuyaqa
in Safari 9 or nightly and try to scroll the iframe (picture) with a MacBook trackpad. The frame will not scroll. Scroll down the outer div to the bottom position and try to scroll the iframe again. The iframe can now be scrolled down, but not up. If the outer div's scroll position is not an any of the top or bottom endpoints the iframe can not be scrolled at all. It is not entirely consistent and sometimes the areas can be scrolled with quick and slightly angled scroll gestures. Using a mouse with a wheel works as expected. Other browsers (FF, Chrome) including Safari 8 does not have the problem with a trackpad.
Attachments
Testcase source
(447 bytes, text/html)
2015-10-15 06:52 PDT
,
Anders Johansson
no flags
Details
Patch
(6.89 KB, patch)
2015-11-06 14:39 PST
,
Wenson Hsieh
bfulgham
: review+
bfulgham
: commit-queue-
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Anders Johansson
Comment 1
2015-10-16 02:37:55 PDT
Previous testpage apparently stopped working due to being created anonymously at JSBin. Here is a new one that hopefully will continue to work.
https://output.jsbin.com/mudada
It needs to be viewed on a full page since nesting inside other iframes won't show the problem.
Radar WebKit Bug Importer
Comment 2
2015-10-16 08:30:13 PDT
<
rdar://problem/23143931
>
Martin Hecko
Comment 3
2015-11-02 15:41:10 PST
I can verify that this is also happening on Safari 9.0.1 (10601.2.7.2) on OS X 10.10.5 as well as one of the recent nightlies
r191902
.
Wenson Hsieh
Comment 4
2015-11-06 14:39:40 PST
Created
attachment 264957
[details]
Patch
Brent Fulgham
Comment 5
2015-11-06 17:13:39 PST
Comment on
attachment 264957
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=264957&action=review
r=me. I had a suggestion for improving the test (to avoid flakiness on the test bots).
> LayoutTests/fast/scrolling/latching/scroll-iframe-in-overflow-expected.txt:2 > +The wrapper's scroll position is: 0
I would suggest these be PASS/FAIL results, to avoid flakiness due to different test machine resolutions and settings.
> LayoutTests/fast/scrolling/latching/scroll-iframe-in-overflow.html:30 > + debug("The wrapper's scroll position is: " + wrapper.scrollTop);
I would suggest something like: if (iframe.contentWindow.scrollY && !wrapper.scrollTop) { testPassed("The iframe scrolled but the wrapper did not."); } else { testFailed("The iframe's scroll position is: " + iframe.contentWindow.scrollY + ", and the wrapper's scroll position is: " + wrapper.scrollTop); }
> LayoutTests/fast/scrolling/latching/scroll-iframe-in-overflow.html:50 > + eventSender.callAfterScrollingCompletes(checkForScroll);
Someday we should make this into a test library function so we can remove all this duplicate code! :-)
Wenson Hsieh
Comment 6
2015-11-06 17:40:59 PST
Comment on
attachment 264957
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=264957&action=review
>> LayoutTests/fast/scrolling/latching/scroll-iframe-in-overflow-expected.txt:2 >> +The wrapper's scroll position is: 0 > > I would suggest these be PASS/FAIL results, to avoid flakiness due to different test machine resolutions and settings.
Will do.
>> LayoutTests/fast/scrolling/latching/scroll-iframe-in-overflow.html:30 >> + debug("The wrapper's scroll position is: " + wrapper.scrollTop); > > I would suggest something like: > if (iframe.contentWindow.scrollY && !wrapper.scrollTop) { > testPassed("The iframe scrolled but the wrapper did not."); > } else { > testFailed("The iframe's scroll position is: " + iframe.contentWindow.scrollY + ", and the wrapper's scroll position is: " + wrapper.scrollTop); > }
Got it. Fixed!
>> LayoutTests/fast/scrolling/latching/scroll-iframe-in-overflow.html:50 >> + eventSender.callAfterScrollingCompletes(checkForScroll); > > Someday we should make this into a test library function so we can remove all this duplicate code! :-)
I agree -- maybe something like sendMomentumScroll(positionX, positionY, dragCount, momentumCount, dragDeltaX, dragDeltaY, momentumDeltaX, momentumDeltaY, handleScrollingComplete) that handles everything in scrollTest() here.
Wenson Hsieh
Comment 7
2015-11-06 18:32:28 PST
Committed
r192124
: <
http://trac.webkit.org/changeset/192124
>
Michael Kuryshev
Comment 8
2017-03-02 05:40:35 PST
Is it fixed yet? I've tried both Safari on the latest Mac OS Sierra and nightly build of webkit and scrolling down inside iframe doesn't work. Scrolling up works fine though.
Anders Johansson
Comment 9
2017-03-02 06:52:06 PST
Yes, works for me now, Safari on Sierra. Updated my last test case with a working image.
Wenson Hsieh
Comment 10
2017-03-02 07:30:46 PST
(In reply to
comment #8
)
> Is it fixed yet? I've tried both Safari on the latest Mac OS Sierra and > nightly build of webkit and scrolling down inside iframe doesn't work. > Scrolling up works fine though.
Hi Michael, Scrolling Anders' test case seems to be working for me as well. If you are still seeing an issue, could you file a followup bug and attach a video clip showing the problem you're seeing? Thanks! Wenson
Michael Kuryshev
Comment 11
2017-03-03 05:45:59 PST
Hi Wenson, Anders, I've created followup bug report with minimal test case. Thanks.
https://bugs.webkit.org/show_bug.cgi?id=169129
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug