position:sticky - composited sticky inside non-composited sticky does not work |
|||
Issue descriptionPunting from this CL: https://codereview.chromium.org/2733633002/ If you have a non-composited sticky element which contains composited sticky elements, CompositedLayerMapping will calculate an incorrect parentRelativeStickyBoxOffset as we don't account for the main-thread sticky offset of our ancestor. Repro: http://output.jsbin.com/hawefav/quiet Options are to: 1. Pass this information through in the sticky constraints. However this would require updating descendants when an ancestor changes - expensive? 2. Force promotion of a sticky element if it has sticky descendants. #2 is likely the best solution.
,
Mar 16 2017
,
Mar 24 2017
Additional test case: http://output.jsbin.com/kahixo uses an overflow scroller rather than the body scroller.
,
May 12 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/de4c11424c87b46a8f5ce0935f9367a868baa507 commit de4c11424c87b46a8f5ce0935f9367a868baa507 Author: smcgruer <smcgruer@chromium.org> Date: Fri May 12 04:16:56 2017 Composite sticky-positioned elements when they have composited descendants In the case of nested sticky elements, if the descendant elements are promoted but their ancestor is not we will position them incorrectly. Instead of trying to re-compute main-thread positioning on the compositor, we can just promote any sticky element that has promoted sticky descendants. This CL goes slightly further and promotes any sticky element that has composited descendants regardless of whether they are sticky - doing so makes the code much simpler and the performance impact should be limited by the fact that sticky is not common. BUG= 702229 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2 Review-Url: https://codereview.chromium.org/2754983002 Cr-Commit-Position: refs/heads/master@{#471217} [modify] https://crrev.com/de4c11424c87b46a8f5ce0935f9367a868baa507/third_party/WebKit/LayoutTests/FlagExpectations/enable-slimming-paint-v2 [add] https://crrev.com/de4c11424c87b46a8f5ce0935f9367a868baa507/third_party/WebKit/LayoutTests/compositing/overflow/mixed-composited-nested-sticky-expected.html [add] https://crrev.com/de4c11424c87b46a8f5ce0935f9367a868baa507/third_party/WebKit/LayoutTests/compositing/overflow/mixed-composited-nested-sticky-overflow-scroller-expected.html [add] https://crrev.com/de4c11424c87b46a8f5ce0935f9367a868baa507/third_party/WebKit/LayoutTests/compositing/overflow/mixed-composited-nested-sticky-overflow-scroller.html [add] https://crrev.com/de4c11424c87b46a8f5ce0935f9367a868baa507/third_party/WebKit/LayoutTests/compositing/overflow/mixed-composited-nested-sticky.html [modify] https://crrev.com/de4c11424c87b46a8f5ce0935f9367a868baa507/third_party/WebKit/Source/core/layout/compositing/CompositingRequirementsUpdater.cpp [modify] https://crrev.com/de4c11424c87b46a8f5ce0935f9367a868baa507/third_party/WebKit/Source/platform/graphics/CompositingReasons.cpp [modify] https://crrev.com/de4c11424c87b46a8f5ce0935f9367a868baa507/third_party/WebKit/Source/platform/graphics/CompositingReasons.h
,
May 12 2017
|
|||
►
Sign in to add a comment |
|||
Comment 1 by flackr@chromium.org
, Mar 16 2017