Boris Zbarsky wrote: > ksachdeva wrote: > > I am trying to develope an extension similar to XmlHttpRequest but for > > a different protocol than Http. > > Note that XMLHttpRequest can make requests to all URIs (file:, ftp:, etc). > Though subject to same-origin checks in some cases. >
That is true but for me it is a different protocol which is not a networking protocol but a protocol for a security device. > > I took the path of implementing the protocol handler for > > my protocol using an example from > > http://www.mozilla.org/projects/netlib/new-handler.html. > > That sounds like the right way to go... now why do you need nsIDocument, > exactly? I was basically copying GetScriptContextFromJSContext(cx) code from nsXmlHttpRequest.cpp which is further called by the GetLoadGroup() method. I need LoadGroup for the same reasons as XmlHttpRequest i.e to automatically abort the pending requests if user leaves the page and pass it to the NS_NewChannel method. Is there any other way to obtain the LoadGroup ? Thanks Boris, appreciate your help and looking for further suggestions. Regards Kapil > > -Boris _______________________________________________ dev-tech-xpcom mailing list [email protected] https://lists.mozilla.org/listinfo/dev-tech-xpcom
