Bug 237745 split app-startup from core appshell functionality

Reland parts of patch following aviary branch landing - already reviewed


git-svn-id: svn://10.0.0.236/trunk@166067 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
bugzilla%arlen.demon.co.uk
2004-12-01 17:26:48 +00:00
parent 307814b03b
commit 8d016ea446
2 changed files with 4 additions and 11 deletions

View File

@@ -47,15 +47,8 @@ function goQuitApplication()
var windowManager = Components.classes['@mozilla.org/appshell/window-mediator;1'].getService();
var windowManagerInterface = windowManager.QueryInterface( Components.interfaces.nsIWindowMediator);
var enumerator = windowManagerInterface.getEnumerator( null );
var appShell = Components.classes['@mozilla.org/appshell/appShellService;1'].getService();
appShell = appShell.QueryInterface( Components.interfaces.nsIAppShellService );
var nativeAppSupport = null;
try {
nativeAppSupport = appShell.nativeAppSupport;
}
catch ( ex ) {
}
var appStartup = Components.classes['@mozilla.org/toolkit/app-startup;1'].
getService(Components.interfaces.nsIAppStartup);
while ( enumerator.hasMoreElements() )
{
@@ -64,7 +57,7 @@ function goQuitApplication()
return false;
domWindow.close();
};
appShell.quit(Components.interfaces.nsIAppShellService.eAttemptQuit);
appStartup.quit(Components.interfaces.nsIAppStartup.eAttemptQuit);
return true;
}

View File

@@ -1709,7 +1709,7 @@ nsExtensionManager.prototype = {
handleCommandLineArgs: function nsExtensionManager_handleCommandLineArgs ()
{
var cmdLineSvc = Components.classes["@mozilla.org/appshell/commandLineService;1"]
var cmdLineSvc = Components.classes["@mozilla.org/app-startup/commandLineService;1"]
.getService(Components.interfaces.nsICmdLineService);
var globalExtension = cmdLineSvc.getCmdLineValue("-install-global-extension");
if (globalExtension)