Commit 53c2adf4 authored by Kris Maglione's avatar Kris Maglione
Browse files

Bug 1586671: Pass callbacks as openDialog argument to profile creation wizard...

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
parent f2eaddfc
......@@ -212,7 +212,8 @@ function createProfileWizard() {
"chrome://mozapps/content/profile/createProfileWizard.xul",
"",
"centerscreen,chrome,modal,titlebar",
ProfileService
ProfileService,
{ CreateProfile }
);
}
......
......@@ -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);
......
......@@ -210,7 +210,8 @@ function CreateProfileWizard() {
"chrome://mozapps/content/profile/createProfileWizard.xul",
"",
"centerscreen,chrome,modal,titlebar",
gProfileService
gProfileService,
{ CreateProfile }
);
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment