Closed Bug 752896 Opened 12 years ago Closed 12 years ago

Add 'DebuggerServer.addRequest'

Categories

(Core :: Gecko Profiler, defect)

x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED WONTFIX

People

(Reporter: BenWa, Assigned: BenWa)

Details

Attachments

(1 file)

Description from bug 751034 comment #10

(In reply to Jan Honza Odvarko from comment #10)
> What about having a 'DebuggerServer.addRequest' API that would allow to
> dynamically extend the 'BrowserRootActor.prototype.requestTypes' array (also
> from within an extension). This way we don't need to change
> dbg-browser-actors.js every time a new actor (a child of the root) appears.
> 
> DebuggerServer.addRequest = function DS_addRequest(aName, aFunction) {
>   DebuggerServer.BrowserRootActor.prototype.requestTypes[aName] =
> function(aRequest) {
>     return aFunction(this, aRequest);
>   }
> };
> 
> This would be similar to what is there for tab actors:
> 'DebuggerServer.addTabRequest'
> 
> The function could live in dbg-browser-actors.js 
> 
> Honza
Attached patch patch (untested)Splinter Review
This patch compiles but is untested.
Assignee: nobody → bgirard
Status: NEW → ASSIGNED
Blocks: 751034
Resolving as wont fix, I discussed this with :past and we decided we wouldn't do it this way. I though I had noted that here but apparently I wrote it in the wrong bug maybe :(?
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → WONTFIX
No longer blocks: 751034
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: