summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb/DOM/Document.h
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2022-09-17 17:36:47 +0200
committerAndreas Kling <kling@serenityos.org>2022-09-17 18:53:26 +0200
commit07c4bf03b59c57b792f5ef4775f9bcf44a8c0194 (patch)
treef3a716aa16cf021e95b81e81e43f2265f1ca644a /Userland/Libraries/LibWeb/DOM/Document.h
parentdf7e64d1036212cc0653895b22384c9601c98f89 (diff)
downloadserenity-07c4bf03b59c57b792f5ef4775f9bcf44a8c0194.zip
LibWeb: Add "scripts to execute in order as soon as possible"
Previously, we had accidentally conflated this set with the similar-but-distinct "scripts to execute as soon as possible".
Diffstat (limited to 'Userland/Libraries/LibWeb/DOM/Document.h')
-rw-r--r--Userland/Libraries/LibWeb/DOM/Document.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/Userland/Libraries/LibWeb/DOM/Document.h b/Userland/Libraries/LibWeb/DOM/Document.h
index eefdf3f281..f4b2ece073 100644
--- a/Userland/Libraries/LibWeb/DOM/Document.h
+++ b/Userland/Libraries/LibWeb/DOM/Document.h
@@ -211,6 +211,10 @@ public:
Vector<JS::Handle<HTML::HTMLScriptElement>> take_scripts_to_execute_as_soon_as_possible(Badge<HTML::HTMLParser>);
Vector<JS::Handle<HTML::HTMLScriptElement>>& scripts_to_execute_as_soon_as_possible() { return m_scripts_to_execute_as_soon_as_possible; }
+ void add_script_to_execute_in_order_as_soon_as_possible(Badge<HTML::HTMLScriptElement>, HTML::HTMLScriptElement&);
+ Vector<JS::Handle<HTML::HTMLScriptElement>> take_scripts_to_execute_in_order_as_soon_as_possible(Badge<HTML::HTMLParser>);
+ Vector<JS::Handle<HTML::HTMLScriptElement>>& scripts_to_execute_in_order_as_soon_as_possible() { return m_scripts_to_execute_in_order_as_soon_as_possible; }
+
QuirksMode mode() const { return m_quirks_mode; }
bool in_quirks_mode() const { return m_quirks_mode == QuirksMode::Yes; }
void set_quirks_mode(QuirksMode mode) { m_quirks_mode = mode; }
@@ -398,7 +402,13 @@ private:
String m_source;
JS::GCPtr<HTML::HTMLScriptElement> m_pending_parsing_blocking_script;
+
Vector<JS::Handle<HTML::HTMLScriptElement>> m_scripts_to_execute_when_parsing_has_finished;
+
+ // https://html.spec.whatwg.org/multipage/scripting.html#list-of-scripts-that-will-execute-in-order-as-soon-as-possible
+ Vector<JS::Handle<HTML::HTMLScriptElement>> m_scripts_to_execute_in_order_as_soon_as_possible;
+
+ // https://html.spec.whatwg.org/multipage/scripting.html#set-of-scripts-that-will-execute-as-soon-as-possible
Vector<JS::Handle<HTML::HTMLScriptElement>> m_scripts_to_execute_as_soon_as_possible;
QuirksMode m_quirks_mode { QuirksMode::No };