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

Issue 2817053002: [blink] Refactor PaintLayerClipper::CalculateClipRects

Created:
3 years, 8 months ago by trchen
Modified:
3 years, 8 months ago
Reviewers:
chrishtr
CC:
blink-reviews, blink-reviews-paint_chromium.org, chromium-reviews, dshwang
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

[blink] Refactor PaintLayerClipper::CalculateClipRects This CL refactors PaintLayerClipper::CalculateClipRects so the code structure becomes more similar to PaintPropertyTreeBuilder. One behavior change is introduced. When the kIgnoreOverflowClip is specified, PLC should skip overflow clip of the root layer. The intention is to be able to paint the whole scrolled contents for composited scrolling. Before this CL, kIgnoreOverflowClip was not honored if the element also has a CSS clip. In such case, both CSS clip and overflow clip would still be applied. With this CL, both CSS clip and overflow clip would be skipped if kIgnoreOverflowClip is specified. This is believed to be a bug that forced us to disable composited scrolling if CSS clip is present. Other than that, no behavior change is introduced. CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+77 lines, -66 lines) Patch
M third_party/WebKit/Source/core/paint/PaintLayerClipper.cpp View 3 chunks +77 lines, -66 lines 0 comments Download

Messages

Total messages: 7 (2 generated)
trchen
I tried to make sure the code works provably equivalent on each of the refactoring ...
3 years, 8 months ago (2017-04-13 19:41:59 UTC) #3
trchen
FYI the workaround I talked about: https://cs.chromium.org/chromium/src/third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp?rcl=6f797ffc358c069eb954a59ea811c12d80208feb&l=1856
3 years, 8 months ago (2017-04-13 19:46:38 UTC) #4
chrishtr
The code here is going to be half-dead after M59, if SPInvalidation succeeds. Is it ...
3 years, 8 months ago (2017-04-13 21:33:44 UTC) #5
trchen
On 2017/04/13 21:33:44, chrishtr wrote: > The code here is going to be half-dead after ...
3 years, 8 months ago (2017-04-13 22:22:01 UTC) #6
chrishtr
3 years, 8 months ago (2017-04-14 17:35:53 UTC) #7
On 2017/04/13 at 22:22:01, trchen wrote:
> On 2017/04/13 21:33:44, chrishtr wrote:
> > The code here is going to be half-dead after M59, if SPInvalidation
succeeds.
> > Is it really worth it to refactor at this very late point? Won't it just
> > introduce potential bugs in SPv1?
> 
> If SPInvalidation sticks, why would it introduce bugs despite the code doesn't
even run? :>

It will run - PaintLayerCompositor will keep calling it.

> When I worked on the other PLC refactoring for the GM version, I noticed that
the interaction between CSS clip and kIgnoreOverflowClip looked questionable
(and did not match non-GM version).

I thought we concluded they were the same after all? Do you still see a
difference?

> I think fixing both would reduce some noises for development in this area.

It is good to keep code clean. I'm just wondering whether there is a specific
goal other than just cleaning the code somewhat.
Along the same lines, this CL also makes a non-refactoring change - why is that
important? And if it is important, it should
be in a separate patch other than the refactoring.

Powered by Google App Engine
This is Rietveld 408576698