mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-28 12:18:56 +00:00
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:
parent
758d816b23
commit
e8d10fb429
Notes:
sideshowbarker
2024-07-18 07:26:43 +09:00
Author: https://github.com/K-Adam
Commit: e8d10fb429
Pull-request: https://github.com/SerenityOS/serenity/pull/9162
Reviewed-by: https://github.com/AtkinsSJ ✅
Reviewed-by: https://github.com/awesomekling
5 changed files with 28 additions and 5 deletions
|
@ -22,6 +22,9 @@ public:
|
|||
unsigned width() const;
|
||||
unsigned height() const;
|
||||
|
||||
virtual bool requires_svg_container() const override { return false; }
|
||||
virtual bool is_svg_container() const override { return true; }
|
||||
|
||||
private:
|
||||
RefPtr<Gfx::Bitmap> m_bitmap;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue