1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 20:27:45 +00:00

LibWeb: Add support for inline SVG element scripts

This commit is contained in:
Shannon Booth 2023-09-26 01:12:21 +13:00 committed by Sam Atkins
parent c4efc0a5aa
commit 4821d284c6
6 changed files with 74 additions and 10 deletions

View file

@ -15,6 +15,10 @@ class SVGScriptElement : public SVGElement {
WEB_PLATFORM_OBJECT(SVGScriptElement, SVGElement);
public:
void process_the_script_element();
void set_source_line_number(Badge<HTML::HTMLParser>, size_t source_line_number) { m_source_line_number = source_line_number; }
protected:
SVGScriptElement(DOM::Document&, DOM::QualifiedName);
@ -22,6 +26,14 @@ protected:
private:
virtual bool is_svg_script_element() const final { return true; }
virtual void visit_edges(Cell::Visitor&) override;
bool m_already_processed { false };
JS::GCPtr<HTML::ClassicScript> m_script;
size_t m_source_line_number { 1 };
};
}