Bug 310156 - File->Import doesn't focus migration wizard if it's already opened. r=mconnor.

This commit is contained in:
mozilla.mano%sent.com 2005-09-28 04:20:07 +00:00
Родитель 0a72f39cc1
Коммит 39d6430f14
2 изменённых файлов: 12 добавлений и 3 удалений

Просмотреть файл

@ -2309,11 +2309,19 @@ function updateToolbarStates(toolbarMenuElt)
function BrowserImport() function BrowserImport()
{ {
#ifdef XP_MACOSX #ifdef XP_MACOSX
var features = "centerscreen,chrome,resizable=no"; var wm = Components.classes["@mozilla.org/appshell/window-mediator;1"]
.getService(Components.interfaces.nsIWindowMediator);
var win = wm.getMostRecentWindow("Browser:MigrationWizard");
if (win)
win.focus();
else {
window.openDialog("chrome://browser/content/migration/migration.xul",
"migration", "centerscreen,chrome,resizable=no");
}
#else #else
var features = "modal,centerscreen,chrome,resizable=no"; window.openDialog("chrome://browser/content/migration/migration.xul",
"migration", "modal,centerscreen,chrome,resizable=no");
#endif #endif
window.openDialog("chrome://browser/content/migration/migration.xul", "migration", features);
} }
function BrowserFullScreen() function BrowserFullScreen()

Просмотреть файл

@ -41,6 +41,7 @@
<wizard id="migrationWizard" <wizard id="migrationWizard"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
windowtype="Browser:MigrationWizard"
title="&migrationWizard.title;" title="&migrationWizard.title;"
onload="MigrationWizard.init()" onload="MigrationWizard.init()"
onunload="MigrationWizard.uninit()" onunload="MigrationWizard.uninit()"