Global history introduced as a service and appropriate changes to
Appshell service and Factory git-svn-id: svn://10.0.0.236/trunk@25912 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -22,6 +22,7 @@
|
||||
#include "nsIComponentManager.h"
|
||||
#include "nsAppShellCIDs.h"
|
||||
#include "nsICmdLineService.h"
|
||||
#include "nsIGlobalHistory.h"
|
||||
|
||||
/* extern the factory entry points for each component... */
|
||||
nsresult NS_NewAppShellServiceFactory(nsIFactory** aFactory);
|
||||
@@ -35,6 +36,7 @@ static NS_DEFINE_IID(kAppShellServiceCID, NS_APPSHELL_SERVICE_CID);
|
||||
static NS_DEFINE_IID(kCmdLineServiceCID, NS_COMMANDLINE_SERVICE_CID);
|
||||
static NS_DEFINE_IID(kProtocolHelperCID, NS_PROTOCOL_HELPER_CID);
|
||||
static NS_DEFINE_IID(kXPConnectFactoryCID, NS_XPCONNECTFACTORY_CID);
|
||||
static NS_DEFINE_IID(kGlobalHistoryCID, NS_GLOBALHISTORY_CID);
|
||||
|
||||
/*
|
||||
* Global entry point to register all components in the registry...
|
||||
@@ -46,6 +48,7 @@ NSRegisterSelf(nsISupports* serviceMgr, const char *path)
|
||||
nsComponentManager::RegisterComponent(kCmdLineServiceCID, NULL, NULL, path, PR_TRUE, PR_TRUE);
|
||||
nsComponentManager::RegisterComponent(kProtocolHelperCID, NULL, NULL, path, PR_TRUE, PR_TRUE);
|
||||
nsComponentManager::RegisterComponent(kXPConnectFactoryCID, NULL, NULL, path, PR_TRUE, PR_TRUE);
|
||||
nsComponentManager::RegisterComponent(kGlobalHistoryCID, NULL, NULL, path, PR_TRUE, PR_TRUE);
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
@@ -59,6 +62,7 @@ NSUnregisterSelf(nsISupports* serviceMgr, const char *path)
|
||||
nsComponentManager::UnregisterFactory(kCmdLineServiceCID, path);
|
||||
nsComponentManager::UnregisterFactory(kProtocolHelperCID, path);
|
||||
nsComponentManager::UnregisterFactory(kXPConnectFactoryCID, path);
|
||||
nsComponentManager::UnregisterFactory(kGlobalHistoryCID, path);
|
||||
|
||||
return NS_OK;
|
||||
}
|
||||
@@ -99,6 +103,9 @@ NSGetFactory(nsISupports* serviceMgr,
|
||||
else if (aClass.Equals(kXPConnectFactoryCID)) {
|
||||
rv = NS_NewXPConnectFactoryFactory(aFactory);
|
||||
}
|
||||
else if (aClass.Equals(kGlobalHistoryCID)) {
|
||||
rv = NS_NewGlobalHistoryFactory(aFactory);
|
||||
}
|
||||
|
||||
#if 0
|
||||
else if (aClass.Equals(kProtocolHelperCID)) {
|
||||
|
||||
Reference in New Issue
Block a user