Bug 116397 - Refactor RenderStyle::diff()
Summary: Refactor RenderStyle::diff()
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Simon Fraser (smfr)
Depends on:
Blocks: 116319
  Show dependency treegraph
Reported: 2013-05-18 13:32 PDT by Simon Fraser (smfr)
Modified: 2013-05-19 19:27 PDT (History)
7 users (show)

See Also:

Patch (26.88 KB, patch)
2013-05-18 14:24 PDT, Simon Fraser (smfr)
kling: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Simon Fraser (smfr) 2013-05-18 13:32:13 PDT
RenderStyle::diff() is tricky for two reasons.

First, there's nothing to enforce the requirement that "more work" diffs have to be detected before "less work" diffs (i.e. we have to always check for changes that result in StyleDifferenceLayout before changes that result in StyleDifferenceRepaint).

Secondly, in some cases, even when we return, say, StyleDifferenceLayoutPositionedMovementOnly or StyleDifferenceRecompositeLayer, we also need to check for changes that require repaint, and that's not possible now.
Comment 1 Simon Fraser (smfr) 2013-05-18 14:24:49 PDT
Created attachment 202217 [details]
Comment 2 Andreas Kling 2013-05-18 18:11:28 PDT
Comment on attachment 202217 [details]

r=me, this is great.
Comment 3 Simon Fraser (smfr) 2013-05-19 19:27:13 PDT