On Wed, Jul 30, 2014 at 9:27 AM, Shanmugham Sundaram <shansyman...@gmail.com
> wrote:

>                doSomething: function(gdomwindow,  siteId, bPage,
> bIsGreater) {
>
>
>  //win.wrappedJSObject.injectedJSFunctioninWebPage(gdomwindow,  siteId,
> bPage, bIsGreater);
>
>                //How to call the injected or page java scripts by using
> nsIDOMWindow??
>
>
Has the function already been injected somehow? In that case, just do
gdomwindow.wrappedJSObject.injectedJSFunctionInWebPage(...).

But really, that's the wrong approach. You should implement your custom
functionality in the doSomething method, and operate on gdomwindow from
there (rather than the scope of the page). That will give you the benefits
of Xray Vision, and make your code more secure:
https://developer.mozilla.org/en-US/docs/Xray_vision
_______________________________________________
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform

Reply via email to