mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 08:48:11 +00:00
LibWeb: Don't call did_layout in non-main frame documents
Fixes https://github.com/SerenityOS/serenity/issues/2649 Loading a page with iframes could lead to a scenario, where the iframe document finished layout prior to the main frame beeing laid out initially. This caused a crash/assertion of the browser.
This commit is contained in:
parent
a5b8cc2d0b
commit
5b6920a18a
1 changed files with 2 additions and 1 deletions
|
@ -246,7 +246,8 @@ void Document::layout()
|
|||
m_layout_root->layout();
|
||||
m_layout_root->set_needs_display();
|
||||
|
||||
frame()->page().client().page_did_layout();
|
||||
if (frame()->is_main_frame())
|
||||
frame()->page().client().page_did_layout();
|
||||
}
|
||||
|
||||
void Document::update_style()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue