Hi,
I finsihed writing an XPCOM component and I can register the component by
calling regxpcom, then deleting xpti.dat and compreg.dat, then restarting
the Firefox browser.
I followed the Weblock sample to try and create a installer (.xpi) file
using XPInstall. I was able to copy the component's .dll and .xpt files in
the "components" folder, but I am at a total loss on how to register my
component so it can be used. What am I missing?!
Thanks in advance!
This is what my install.js looks like (packaged in the .xpi file):
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// initialize the installation
var err = initInstall("DYMO XPCOM", "dymoxpcom", 1.0);
logComment("initInstall(): " + err);
var componentsFolder = getFolder("Components");
logComment("componentsFolder = " + componentsFolder);
{
// add the DLL and say where it'll go
addFile("dymoxpcom.dll", "1.0", "dymoxpcom.dll", componentsFolder, "");
logComment("addFile() dymoxpcom.dll: " + err);
// add the typelib also
addFile("dymoxpcom.xpt", "1.0", "dymoxpcom.xpt", componentsFolder, "");
logComment("addFile() dymoxpcom.xpi: " + err);
// perform the installation if there are no errors
if (err == SUCCESS)
{
err = performInstall();
logComment("PerformInstall(): " + err);
err = refreshPlugins(true);
logComment("refreshPlugins(): " + err);
}
else
cancelInstall(err);
}
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////
_______________________________________________
Mozilla-xpcom mailing list
[email protected]
http://mail.mozilla.org/listinfo/mozilla-xpcom