2008/6/11, Boris Zbarsky <[EMAIL PROTECTED]>: > Jürgen Herz wrote: >> But I can't see how to get from the image URL of scheme mailbox://, >> news:// or imap:// to a nsIInputStream. > > The best thing to do here is to create a channel for the nsIURI, then > asyncOpen it and have a stream listener to read the data. If you really need > to buffer the data up into a single stream, you could either use open() > instead > of asyncOpen()
Wow, that was easy. And works well as far as I tested it. > or copy the data into a pipe in your streamlistener. The latter is probably > better in terms of playing nice with other code. But already nearly drove me nuts when I was thinking about. The code to be executed on the data is called when a dialog opens. So what to do until the callback is called on onStopRequest by the stream listener? That's just to heavy for me at the moment. But thanks you anyway, you still helped me. Juergen _______________________________________________ dev-tech-network mailing list [email protected] https://lists.mozilla.org/listinfo/dev-tech-network
