Bug 1586671: Pass callbacks as openDialog argument to profile creation wizard rather than using window.opener. r=mossop

Differential Revision: https://phabricator.services.mozilla.com/D48717

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Kris Maglione 2019-10-09 16:59:13 +00:00
parent f2eaddfc8f
commit 53c2adf481
3 changed files with 6 additions and 6 deletions

View File

@ -212,7 +212,8 @@ function createProfileWizard() {
"chrome://mozapps/content/profile/createProfileWizard.xul",
"",
"centerscreen,chrome,modal,titlebar",
ProfileService
ProfileService,
{ CreateProfile }
);
}

View File

@ -253,11 +253,9 @@ function onFinish(event) {
return;
}
// window.opener is false if the Create Profile Wizard was opened from the
// command line.
if (window.opener) {
if (window.arguments && window.arguments[1]) {
// Add new profile to the list in the Profile Manager.
window.opener.CreateProfile(profile);
window.arguments[1].CreateProfile(profile);
} else {
// Use the newly created Profile.
var profileLock = profile.lock(null);

View File

@ -210,7 +210,8 @@ function CreateProfileWizard() {
"chrome://mozapps/content/profile/createProfileWizard.xul",
"",
"centerscreen,chrome,modal,titlebar",
gProfileService
gProfileService,
{ CreateProfile }
);
}