mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-27 02:05:07 +02:00
LibWeb: Flesh out most of the "unload" algorithm for documents
Yet another small steps towards spec-compliant document lifecycles.
This commit is contained in:
Notes:
sideshowbarker
2024-07-17 10:05:47 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/0c7ab663c1
@@ -39,6 +39,11 @@ public:
|
||||
void spin_until(Function<bool()> goal_condition);
|
||||
void process();
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/browsing-the-web.html#termination-nesting-level
|
||||
size_t termination_nesting_level() const { return m_termination_nesting_level; }
|
||||
void increment_termination_nesting_level() { ++m_termination_nesting_level; }
|
||||
void decrement_termination_nesting_level() { --m_termination_nesting_level; }
|
||||
|
||||
Task const* currently_running_task() const { return m_currently_running_task; }
|
||||
|
||||
JS::VM& vm() { return *m_vm; }
|
||||
@@ -96,6 +101,9 @@ private:
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/webappapis.html#backup-incumbent-settings-object-stack
|
||||
Vector<EnvironmentSettingsObject&> m_backup_incumbent_settings_object_stack;
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/browsing-the-web.html#termination-nesting-level
|
||||
size_t m_termination_nesting_level { 0 };
|
||||
};
|
||||
|
||||
EventLoop& main_thread_event_loop();
|
||||
|
||||
Reference in New Issue
Block a user