Files
ladybird/Libraries/LibWeb/DOM
Andreas Kling 2ab80c9e47 LibWeb: Ensure hosted document layout is up to date before painting
When painting a navigable container (iframe/object), the hosted
document's layout may have been invalidated during the parent
document's layout pass via did_set_content_size -> set_viewport_size
-> set_needs_layout_update.

If the hosted document is not in the event loop's docs list (e.g.,
it was created during a rAF callback after the list was built), its
layout would never be re-updated, causing a VERIFY failure in
Node::paintable() which asserts layout_is_up_to_date().

Fix this by calling update_layout() on the hosted document in
NavigableContainerViewportPaintable::paint() before accessing its
paintable. This is a no-op when layout is already current.

Fixes #8297.
2026-03-20 22:55:44 -05:00
..
2026-01-31 11:44:20 +01:00