mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-02 22:30:31 +00:00
LibWeb: Use separate restore() for each ApplyFilters display list item
ApplyFilter internally calls canvas.saveLayer() which requires a
matching canvas.restore() to be called.
Fixes painting on https://supabase.com/ regressed by
8562b0e33b
This commit is contained in:
parent
30c8510725
commit
c94b4316e7
Notes:
github-actions[bot]
2024-12-01 15:13:10 +00:00
Author: https://github.com/kalenikaliaksandr
Commit: c94b4316e7
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/2680
2 changed files with 18 additions and 4 deletions
|
@ -327,7 +327,11 @@ void StackingContext::paint(PaintContext& context) const
|
|||
context.display_list_recorder().push_scroll_frame_id(*paintable_box().scroll_frame_id());
|
||||
}
|
||||
context.display_list_recorder().push_stacking_context(push_stacking_context_params);
|
||||
context.display_list_recorder().apply_filters(paintable_box().computed_values().filter());
|
||||
|
||||
auto const& filter = computed_values.filter();
|
||||
if (!filter.is_none()) {
|
||||
context.display_list_recorder().apply_filters(paintable_box().computed_values().filter());
|
||||
}
|
||||
|
||||
if (auto mask_image = computed_values.mask_image()) {
|
||||
auto mask_display_list = DisplayList::create();
|
||||
|
@ -348,6 +352,10 @@ void StackingContext::paint(PaintContext& context) const
|
|||
}
|
||||
}
|
||||
|
||||
if (!filter.is_none()) {
|
||||
context.display_list_recorder().restore();
|
||||
}
|
||||
|
||||
paint_internal(context);
|
||||
context.display_list_recorder().pop_stacking_context();
|
||||
if (paintable_box().scroll_frame_id().has_value()) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue