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

Issue 2840143002: [cc] Change semantics of fixed-pos container layer

Created:
3 years, 8 months ago by trchen
Modified:
3 years, 5 months ago
CC:
blink-reviews, blink-reviews-frames_chromium.org, blink-reviews-layout_chromium.org, cc-bugs_chromium.org, chromium-reviews, eae+blinkwatch, jchaffraix+rendering, leviw+renderwatch, pdr+renderingwatchlist_chromium.org, szager+layoutwatch_chromium.org, zoltan1
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

[cc] Change semantics of fixed-pos container layer In the old semantics, when we set a layer to be fixed-pos container, it means descendant fixed-pos layers don't move relative to the current layer's parent. This made it impossible (without extra dummy layers) to correctly implement fixed-pos container that has overflow scroll, because in this case fixed-pos descendants do scroll along (don't move relative to the scrolling layer, instead of its parent). This CL changes the semantics of the fixed-pos container flag, so the fixed-pos container layer itself becomes the anchor of fixed-pos descendants, instead of its parent. BUG=715338 CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2

Patch Set 1 #

Total comments: 3

Patch Set 2 : update tests #

Patch Set 3 : add back inner viewport container layer as fixed-pos container #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+21 lines, -31 lines) Patch
M cc/layers/layer.h View 1 1 chunk +1 line, -0 lines 0 comments Download
M cc/layers/layer_position_constraint_unittest.cc View 1 9 chunks +3 lines, -13 lines 0 comments Download
M cc/test/layer_tree_test.cc View 1 1 chunk +1 line, -2 lines 1 comment Download
M cc/trees/layer_tree_host.cc View 1 1 chunk +0 lines, -1 line 0 comments Download
M cc/trees/layer_tree_host_common_unittest.cc View 1 2 chunks +3 lines, -3 lines 0 comments Download
M cc/trees/property_tree_builder.cc View 1 1 chunk +9 lines, -9 lines 0 comments Download
M third_party/WebKit/Source/core/frame/VisualViewport.cpp View 1 2 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/layout/compositing/PaintLayerCompositor.cpp View 1 chunk +3 lines, -2 lines 0 comments Download

Messages

Total messages: 19 (13 generated)
trchen
I've been away from this outer/inner viewport stuff for too long... Needs pairs of extra ...
3 years, 8 months ago (2017-04-25 23:46:16 UTC) #7
bokan
https://codereview.chromium.org/2840143002/diff/1/cc/trees/layer_tree_host.cc File cc/trees/layer_tree_host.cc (right): https://codereview.chromium.org/2840143002/diff/1/cc/trees/layer_tree_host.cc#newcode1159 cc/trees/layer_tree_host.cc:1159: DCHECK(page_scale_layer_->IsContainerForFixedPositionLayers()); I think this DCHECK should be for the ...
3 years, 8 months ago (2017-04-26 21:17:56 UTC) #10
trchen
Updated unittests. Also changed CL description because the old behavior feels more like a (badly) ...
3 years, 7 months ago (2017-05-01 21:24:13 UTC) #12
trchen
Ping. What do you think? I'm a little bit uncertain about this CL because it's ...
3 years, 7 months ago (2017-05-04 20:37:26 UTC) #17
aelias_OOO_until_Jul13
lgtm, but please also wait for bokan@ review
3 years, 7 months ago (2017-05-04 20:40:08 UTC) #18
bokan
3 years, 7 months ago (2017-05-09 22:27:21 UTC) #19
Sorry for the delay, just got back from vacay.

lgtm % comment.

https://codereview.chromium.org/2840143002/diff/40001/cc/test/layer_tree_test.cc
File cc/test/layer_tree_test.cc (left):

https://codereview.chromium.org/2840143002/diff/40001/cc/test/layer_tree_test...
cc/test/layer_tree_test.cc:68:
inner_viewport_scroll_layer->SetIsContainerForFixedPositionLayers(true);
If we're going to keep the inner viewport as a container for fixed position
layers we should keep it so in tests too.

Powered by Google App Engine
This is Rietveld 408576698