Create source actors from Debugger API notifications

Co-authored-by: atbrakhi <atbrakhi@igalia.com>
Signed-off-by: Delan Azabani <dazabani@igalia.com>
This commit is contained in:
Delan Azabani 2025-07-29 18:45:20 +08:00
parent e2eabd41c9
commit 048d0b0538
13 changed files with 193 additions and 64 deletions

View file

@ -7,4 +7,11 @@
[Exposed=DebuggerGlobalScope]
interface DebuggerEvent : Event {
readonly attribute object global;
readonly attribute PipelineId pipelineId;
};
[Exposed=DebuggerGlobalScope]
interface PipelineId {
readonly attribute unsigned long namespaceId;
readonly attribute unsigned long index;
};

View file

@ -6,4 +6,24 @@
// web pages.
[Global=DebuggerGlobalScope, Exposed=DebuggerGlobalScope]
interface DebuggerGlobalScope: GlobalScope {
undefined notifyNewSource(NotifyNewSource args);
};
// http://dev.w3.org/csswg/cssom-view/#extensions-to-the-window-interface
dictionary NotifyNewSource {
required PipelineIdInit pipelineId;
required unsigned long spidermonkeyId;
required DOMString url;
required DOMString text;
// FIXME: error[E0599]: the method `trace` exists for reference `&Option<TypedArray<Uint8, *mut JSObject>>`, but
// its trait bounds were not satisfied
// Uint8Array binary;
// TODO: contentType
};
dictionary PipelineIdInit {
required unsigned long namespaceId;
required unsigned long index;
};