I am working on a wrapper for nsIHttpChannel with the interface of 
MLHttpRequest. Mainly to be able to use the codeBbasePrincipal (or 
ContextPrincipal as it is called now I think) with XHR requests, but without 
authors having to rewrite their code.

This is for Thunderbird Add-Ons, which still can access nsIHttpChannel.

I am pretty far and it is working nicely.

However, I was not able to find a place in the nsIHttpChannel specification, 
which I could map to

XMLHttpRequest.overrideMimeType()

Is there any option/requirement to manually overide the MimeType of responses 
received via a nsIStreamListener or a nsIStreamLoaderObserver.

The wrapper is here, if you want to have a look:
https://gitlab.com/jobisoft/CardBook/blob/Thunderbird67+/chrome/content/cardbookHttpRequest.js

Thanks for any help,
John
_______________________________________________
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform

Reply via email to