Open
Bug 209176
Opened 22 years ago
Updated 2 years ago
xpcshell and JS shell should share their code
Categories
(Core :: XPConnect, enhancement, P3)
Core
XPConnect
Tracking
()
NEW
People
(Reporter: dbradley, Unassigned)
References
(Depends on 1 open bug)
Details
90% of the code is the same, I think. I think XPCShell could include a common
file shared with js. This wouldn't require adding any static libs or anything
and would be simple and light weight to implement. I'm thinking that the shared
file would allow call a shell specific function supplied by each respectively.
I'm thinking an initialize function and a parameter processing function, to
handle any shell specific parameters.
Updated•18 years ago
|
Assignee: dbradley → nobody
Updated•18 years ago
|
QA Contact: pschwartau → xpconnect
Comment 1•16 years ago
|
||
You'd need to learn a bit about XPCOM and the JSAPI, but I think this is a doable first bug (if perhaps a slightly ambitious one).
Whiteboard: [good first bug]
Reporter | ||
Comment 2•16 years ago
|
||
A bit more ambitious approach might be to put some hooks into JS Shell that would allow extending it. Then just add in an XPConnect extension. No more two shell apps. This would allow other extensions and more wide spread use of JS Shell.
This might not be nothing more than passing the extension the global object so that the extension could add in its functionality.
Not sure how difficult this would be to do in a cross platform manner.
Comment 3•14 years ago
|
||
It would be really great to extend this to cover ipc/testshell/XPCShellEnvironment.cpp as well, since it's yet another environment with very similar blocks of code.
I'd like to tackle this bug but would love some assistance in figuring out the architecture before getting started.
It seems that there are two solutions presented so far:
1. Have a common file that is shared by XPCShell and JSShell containing the common code, with wrappers in each version to access the common functions.
2. Add hooks into JSShell and implement XPCShell as an extension using the hooks.
I can probably figure out how to do (1) by myself but will likely need help with (2).
The question is, which approach is better for Mozilla? Are there any other approaches that haven't been listed yet?
Comment 5•14 years ago
|
||
(2) sounds like the way to go.
Updated•14 years ago
|
Assignee: nobody → szu.han.chang
I'd like to propose that the goal of this bug will be to implement XPC shell using the JS shell API developed for the resolution of bug 687122.
Comment 7•12 years ago
|
||
Given how we're classifying bug types these days, this isn't good first bug fodder.
Assignee: szu.han.chang → nobody
Whiteboard: [good first bug]
Updated•7 years ago
|
Priority: -- → P3
Updated•2 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•