mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-28 19:59:17 +00:00
LibWeb: Don't traverse entire layout tree in every HTML::EventLoop tick
Instead, collect a list of all the elements with content-visibility:auto after layout. This way we can skip the tree traversal when updating the rendering. This was previously eating up ~300 µs of the 60fps frame budget on our GitHub repo pages (and even more on large pages).
This commit is contained in:
parent
df0dc32006
commit
07ff75bbec
Notes:
github-actions[bot]
2025-06-11 14:26:45 +00:00
Author: https://github.com/awesomekling
Commit: 07ff75bbec
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5059
4 changed files with 22 additions and 8 deletions
|
@ -395,6 +395,7 @@ void ViewportPaintable::visit_edges(Visitor& visitor)
|
|||
{
|
||||
Base::visit_edges(visitor);
|
||||
visitor.visit(clip_state);
|
||||
visitor.visit(m_paintable_boxes_with_auto_content_visibility);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue