LibWeb/HTML: Hook up a WorkerAgent for web workers

This commit is contained in:
Shannon Booth
2025-04-24 15:22:25 +12:00
committed by Andreas Kling
parent 5290ebfe19
commit 041ff0c7ff
Notes: github-actions[bot] 2025-04-25 14:45:27 +00:00
10 changed files with 78 additions and 12 deletions

View File

@@ -32,7 +32,15 @@ struct WebEngineCustomJobCallbackData final : public JS::JobCallback::CustomData
HTML::Script* active_script();
void initialize_main_thread_vm(HTML::EventLoop::Type);
enum class AgentType : u8 {
SimilarOriginWindow,
DedicatedWorker,
SharedWorker,
ServiceWorker,
Worklet,
};
void initialize_main_thread_vm(AgentType);
JS::VM& main_thread_vm();
void queue_mutation_observer_microtask(DOM::Document const&);