Bug 1515966 - Download notification click action now opens about:downloads. r=sdaswani

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

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Vlad Baicu 2018-12-28 14:50:38 +00:00
parent cbb94950ec
commit b0e869dfdd

View File

@ -160,7 +160,7 @@ var DownloadNotifications = {
this.showInAboutDownloads(download);
}
} else {
ConfirmCancelPrompt.show(download);
this.showInAboutDownloads(download);
}
}).catch(Cu.reportError);
},
@ -275,19 +275,6 @@ DownloadNotification.prototype = {
},
};
var ConfirmCancelPrompt = {
show: function(download) {
// Open a prompt that offers a choice to cancel the download
let title = strings.GetStringFromName("downloadCancelPromptTitle1");
let message = strings.GetStringFromName("downloadCancelPromptMessage1");
if (Services.prompt.confirm(null, title, message)) {
download.cancel().catch(Cu.reportError);
download.removePartialData().catch(Cu.reportError);
}
},
};
function DownloadNotificationButton(buttonId, iconUrl, titleStringName, onClicked) {
this.buttonId = buttonId;
this.title = strings.GetStringFromName(titleStringName);