Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(470)

Issue 2336013002: ScrollRectToVisible should bubble up through its layout container. (Closed)

Created:
4 years, 3 months ago by sunyunjia
Modified:
4 years, 3 months ago
Reviewers:
bokan, skobes
CC:
chromium-reviews, blink-reviews, dshwang, slimming-paint-reviews_chromium.org, blink-reviews-paint_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

ScrollRectToVisible should bubble up through its layout container. Previously, ScrollRectToVisible bubbles up through its dom parent. It works fine when its layout container is its dom parent, but this is not the case for absolute-positioned elements. Simply scrolling the dom parent of an absolute-positioned element wouldn't put the desired rect into view. This patch changes the behavior by bubbling up through its layout parent. BUG=645841 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2 Committed: https://crrev.com/57da1c75484e5a3f0af03d038c43e6f23e1549e8 Cr-Commit-Position: refs/heads/master@{#419197}

Patch Set 1 #

Patch Set 2 : Modify the test for Mac #

Total comments: 2

Patch Set 3 : maximum==minimum #

Total comments: 2

Patch Set 4 : Use LayoutBox::canBeProgramaticallyScrolled #

Patch Set 5 : Bubbling up through the layout container. #

Total comments: 1

Patch Set 6 : Use containingBox() instead. #

Patch Set 7 : Improve the visual effect of the test. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+25 lines, -3 lines) Patch
A third_party/WebKit/LayoutTests/fast/scrolling/absolute-position-overflow-clip.html View 1 2 3 4 5 6 1 chunk +22 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutBox.cpp View 1 2 3 4 5 1 chunk +3 lines, -3 lines 0 comments Download

Messages

Total messages: 66 (46 generated)
sunyunjia
PTAL, thanks!
4 years, 3 months ago (2016-09-13 13:03:08 UTC) #15
bokan
https://codereview.chromium.org/2336013002/diff/20001/third_party/WebKit/LayoutTests/fast/scrolling/absolute-position-overflow-clip.html File third_party/WebKit/LayoutTests/fast/scrolling/absolute-position-overflow-clip.html (right): https://codereview.chromium.org/2336013002/diff/20001/third_party/WebKit/LayoutTests/fast/scrolling/absolute-position-overflow-clip.html#newcode18 third_party/WebKit/LayoutTests/fast/scrolling/absolute-position-overflow-clip.html:18: document.getElementById("mydiv").appendChild(focusable); The test would be more clear if you ...
4 years, 3 months ago (2016-09-13 14:38:46 UTC) #16
sunyunjia
All done. PTAL, thanks!
4 years, 3 months ago (2016-09-13 15:19:26 UTC) #19
bokan
https://codereview.chromium.org/2336013002/diff/80001/third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp File third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp (right): https://codereview.chromium.org/2336013002/diff/80001/third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp#newcode1420 third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp:1420: return LayoutRect(box().localToAbsoluteQuad(FloatQuad(FloatRect(intersection(layerBounds, localExposeRect))), UseTransforms).boundingBox()); Sorry, probably should have asked ...
4 years, 3 months ago (2016-09-13 15:32:29 UTC) #22
sunyunjia
https://codereview.chromium.org/2336013002/diff/80001/third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp File third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp (right): https://codereview.chromium.org/2336013002/diff/80001/third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp#newcode1420 third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp:1420: return LayoutRect(box().localToAbsoluteQuad(FloatQuad(FloatRect(intersection(layerBounds, localExposeRect))), UseTransforms).boundingBox()); On 2016/09/13 15:32:29, bokan wrote: ...
4 years, 3 months ago (2016-09-13 16:00:44 UTC) #23
bokan
On 2016/09/13 16:00:44, sunyunjia wrote: > https://codereview.chromium.org/2336013002/diff/80001/third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp > File third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp (right): > > https://codereview.chromium.org/2336013002/diff/80001/third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp#newcode1420 > ...
4 years, 3 months ago (2016-09-13 16:12:30 UTC) #24
bokan
On 2016/09/13 16:12:30, bokan wrote: > On 2016/09/13 16:00:44, sunyunjia wrote: > > > https://codereview.chromium.org/2336013002/diff/80001/third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp ...
4 years, 3 months ago (2016-09-13 16:13:22 UTC) #25
sunyunjia
Done. PTAL, thanks!
4 years, 3 months ago (2016-09-13 18:24:07 UTC) #28
bokan
lgtm! thanks!
4 years, 3 months ago (2016-09-13 18:24:51 UTC) #29
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2336013002/100001
4 years, 3 months ago (2016-09-13 18:29:23 UTC) #31
commit-bot: I haz the power
Try jobs failed on following builders: linux_layout_tests_slimming_paint_v2 on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_layout_tests_slimming_paint_v2/builds/494)
4 years, 3 months ago (2016-09-13 19:13:50 UTC) #33
bokan
lgtm to the minimum == maximum check
4 years, 3 months ago (2016-09-13 21:56:05 UTC) #34
sunyunjia
PTAL, thanks!
4 years, 3 months ago (2016-09-15 19:43:44 UTC) #44
bokan
Thanks! This looks better to me. +skobes though as he's more familiar with layout structures. ...
4 years, 3 months ago (2016-09-15 20:54:41 UTC) #48
skobes
The change seems reasonable. However the bug says this is a regression since M54... do ...
4 years, 3 months ago (2016-09-16 01:43:48 UTC) #53
sunyunjia
On 2016/09/16 01:43:48, skobes wrote: > The change seems reasonable. However the bug says this ...
4 years, 3 months ago (2016-09-16 13:57:06 UTC) #54
skobes
lgtm On 2016/09/16 13:57:06, sunyunjia wrote: > On 2016/09/16 01:43:48, skobes wrote: > > The ...
4 years, 3 months ago (2016-09-16 16:47:04 UTC) #59
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2336013002/160001
4 years, 3 months ago (2016-09-16 17:07:39 UTC) #62
commit-bot: I haz the power
Committed patchset #7 (id:160001)
4 years, 3 months ago (2016-09-16 17:13:41 UTC) #64
commit-bot: I haz the power
4 years, 3 months ago (2016-09-16 17:16:03 UTC) #66
Message was sent while issue was closed.
Patchset 7 (id:??) landed as
https://crrev.com/57da1c75484e5a3f0af03d038c43e6f23e1549e8
Cr-Commit-Position: refs/heads/master@{#419197}

Powered by Google App Engine
This is Rietveld 408576698