Bug 192322 - CSS Painting API callbacks should be called before rendering
Summary: CSS Painting API callbacks should be called before rendering
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
Depends on:
Blocks: 190217
  Show dependency treegraph
Reported: 2018-12-03 14:06 PST by Justin Michaud
Modified: 2018-12-03 14:19 PST (History)
4 users (show)

See Also:


Note You need to log in before you can comment on or make changes to this bug.
Description Justin Michaud 2018-12-03 14:06:38 PST
The callbacks should be called at RAF time, not during paint. Possibly consider using StyleDidChange to determine if the custom paint element needs to be repainted, instead of the code in RenderStyle::changeRequiresRepaint. This also means that the responsibleDocument()->renderView()->repaintRootContents() repaint in PaintWorkletGlobalScope::registerPaint can be replaced with repainting only affected custom paint images.
Comment 1 Simon Fraser (smfr) 2018-12-03 14:18:51 PST
The "before rendering" may change soon (when we fix rAF callback timing).