зеркало из https://github.com/mozilla/gecko-dev.git
More test updates.
This commit is contained in:
Родитель
affac5fac7
Коммит
1fbc621a41
|
@ -5,31 +5,26 @@
|
|||
static NS_DEFINE_IID(kIStreamConverterIID, NS_ISTREAM_CONVERTER_IID);
|
||||
static NS_DEFINE_CID(kRFC822toHTMLStreamConverterCID, NS_RFC822_HTML_STREAM_CONVERTER_CID);
|
||||
|
||||
/* This is just a testing stub added by mscott. All I'm doing is loading a component,
|
||||
and querying it for a particular interface.
|
||||
|
||||
It is its only purpose / use....
|
||||
|
||||
/*
|
||||
* This is just a testing for libmime. All I'm doing is loading a component,
|
||||
* and querying it for a particular interface. It is its only purpose / use....
|
||||
*/
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
nsRFC822toHTMLStreamConverter *sample;
|
||||
|
||||
// register our dll
|
||||
nsRepository::RegisterFactory(kRFC822toHTMLStreamConverterCID, "mime.dll", PR_FALSE, PR_FALSE);
|
||||
nsRepository::RegisterFactory(kRFC822toHTMLStreamConverterCID,
|
||||
"mime.dll", PR_FALSE, PR_FALSE);
|
||||
|
||||
nsresult res = nsRepository::CreateInstance(kRFC822toHTMLStreamConverterCID,
|
||||
NULL,
|
||||
kIStreamConverterIID,
|
||||
(void **) &sample);
|
||||
|
||||
NULL, kIStreamConverterIID, (void **) &sample);
|
||||
if (res == NS_OK && sample)
|
||||
{
|
||||
void *stream;
|
||||
|
||||
printf("We succesfully obtained a nsRFC822toHTMLStreamConverter interface....\n");
|
||||
|
||||
// sample->ParseRFC822Addresses("Scott MacGregor <mscott@netscape.com>", &names, &addresses);
|
||||
|
||||
sample->SetOutputStream((nsIOutputStream *)stream);
|
||||
printf("Releasing the interface now...\n");
|
||||
sample->Release();
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче