diff options
author | Andreas Kling <kling@serenityos.org> | 2020-06-06 22:13:24 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-06-06 22:15:17 +0200 |
commit | 5e9d1b216596b936100f34640d43dc534fc35cbf (patch) | |
tree | f2d4a464f49964a95d719a9b561df1a6202c8b64 /Libraries | |
parent | 39ad42defdcb01f1fb0ffc83ee53b9152630f14f (diff) | |
download | serenity-5e9d1b216596b936100f34640d43dc534fc35cbf.zip |
LibWeb: Whine in debug log instead of asserting on partial layout FIXME
We don't support incremental relayout of subtrees (only single nodes)
but let's not crash the browser just because this happens. We can keep
the browser up and just complain in the debug log instead.
Diffstat (limited to 'Libraries')
-rw-r--r-- | Libraries/LibWeb/Layout/LayoutTreeBuilder.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Libraries/LibWeb/Layout/LayoutTreeBuilder.cpp b/Libraries/LibWeb/Layout/LayoutTreeBuilder.cpp index d266a4f61e..1ed4397c2f 100644 --- a/Libraries/LibWeb/Layout/LayoutTreeBuilder.cpp +++ b/Libraries/LibWeb/Layout/LayoutTreeBuilder.cpp @@ -79,8 +79,10 @@ static RefPtr<LayoutNode> create_layout_tree(Node& node, const StyleProperties* RefPtr<LayoutNode> LayoutTreeBuilder::build(Node& node) { - // FIXME: Support building partial trees. - ASSERT(is<Document>(node) || !node.has_children()); + if (!is<Document>(node) && node.has_children()) { + dbg() << "FIXME: Support building partial layout trees."; + return nullptr; + } return create_layout_tree(node, nullptr); } |