LibWeb: Ignore svg elements outside of <svg> when building layout tree

An svg layout element without a `SVGSVGElement` ancestor caused a failed
assertion before, because the svg context does not exist when `paint()`
is called
This commit is contained in:
K-Adam 2021-08-05 10:26:09 +02:00 committed by Andreas Kling
commit e8d10fb429
Notes: sideshowbarker 2024-07-18 07:26:43 +09:00
5 changed files with 28 additions and 5 deletions

View file

@ -14,6 +14,8 @@ class SVGElement : public DOM::Element {
public:
using WrapperType = Bindings::SVGElementWrapper;
virtual bool requires_svg_container() const override { return true; }
protected:
SVGElement(DOM::Document&, QualifiedName);
};