Skip to content

Commit

Permalink
Register PaintLayer as client on backdrop-filter
Browse files Browse the repository at this point in the history
A PaintLayer with a backdrop-filter applied wasn't added as a client to
the filter. This meant that it wouldn't get any notifications when the
contents of a filter was mutated.

Add client registration/unregistration to PaintLayer
(UpdateBackdropFilters and Destroy).

Bug: 359102842
Change-Id: Id664e680acb47860a931dc4b1b91142a19521950
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5824402
Commit-Queue: Philip Rogers <[email protected]>
Auto-Submit: Fredrik Söderquist <[email protected]>
Reviewed-by: Philip Rogers <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1348693}
  • Loading branch information
Fredrik Söderquist authored and chromium-wpt-export-bot committed Aug 29, 2024
1 parent 980adbd commit 1dd1793
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions css/filter-effects/backdrop-filter-reference-filter-mutated.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<!doctype html>
<html class="reftest-wait">
<title>backdrop-filter: A reference filter is mutated</title>
<link rel="help" href="https://drafts.fxtf.org/filter-effects-2/#BackdropFilterProperty">
<link rel="match" href="reference/green-100x100.html">
<script src="/common/reftest-wait.js"></script>
<script src="/common/rendering-utils.js"></script>
<div style="width: 100px; height: 100px; backdrop-filter: url(#f)"></div>
<svg height="0">
<defs>
<filter id="f">
<feFlood id="flood" flood-color="red"/>
</filter>
</defs>
</svg>
<script>
waitForAtLeastOneFrame().then(() => {
const flood = document.getElementById('flood');
flood.setAttribute('flood-color', 'green');
takeScreenshot();
});
</script>

0 comments on commit 1dd1793

Please sign in to comment.