DOMEvents will be forced to be C++ only. Right now properly implemented DOM Events
are already C++ only, but apparently there is at least one JS implementation too
(which doesn't work at all with event dispatching code).
Created attachment 633215 [details] [diff] [review]
I had to refactor the IDL to move the Application object definition in its own file since it is use in the dictionnary, hence the include change to nsGlobalWindow.h
Comment on attachment 633215 [details] [diff] [review]
>+interface mozIDOMApplication : nsISupports
Nit, extra space before :
>+ readonly attribute jsval manifest;
>+ readonly attribute DOMString manifestURL;
>+ readonly attribute nsIArray receipts; /* an array of strings */
Not about this bug, but huh. Why do we expose nsIArray to web. We really shouldn't do that.
But I don't understand why you need to move Application interface.
(In reply to Olli Pettay [:smaug] from comment #2)
> Not about this bug, but huh. Why do we expose nsIArray to web. We really
> shouldn't do that.
Yep, I plan to move that to a jsval.
> But I don't understand why you need to move Application interface.
since the dictionnary is :
and mozIDOMApplication is not a built-in type, the code generator that uses dictionary_helper_gen.conf looks for a "mozIDOMApplication.h" header file.
Couldn't you add mozIDOMApplication to exclude_automatic_type_include
and perhaps nsIDOMApplicationRegistry.h to special_includes
(In reply to Olli Pettay [:smaug] from comment #5)
> ...in dictionary_helper_gen.conf
I didn't know about these. I'll update my patch, thanks!
Created attachment 633285 [details] [diff] [review]
Updated to use exclude_automatic_type_include.
Comment on attachment 633285 [details] [diff] [review]
Nit, mozIDOMApplication **aApplication
>+ nsCOMPtr<mozIDOMApplication> mApplication;
Almost missed... you have strong pointer to Application, so you need to add it to
cycle collection. (You can check nsDOMCustomEvent as an example. It has mDetail as a strong member variable.)
Created attachment 633297 [details] [diff] [review]
Now with cycle collection for mApplication.
*** Bug 765287 has been marked as a duplicate of this bug. ***