Bug 1652344 p1. Remove the code in nsGlobalWindowOuter::PrintOuter for handling failure to get an nsIPrintSettingsService. r=bobowen

All our backends implement nsIPrintSettingsService, so this code is unused.

Differential Revision: https://phabricator.services.mozilla.com/D83267
This commit is contained in:
Jonathan Watt 2020-07-12 19:32:25 +00:00
Родитель 2ac85191d6
Коммит 185c6d1087
1 изменённых файлов: 1 добавлений и 4 удалений

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

@ -5191,8 +5191,8 @@ void nsGlobalWindowOuter::PrintOuter(ErrorResult& aError) {
nsCOMPtr<nsIPrintSettingsService> printSettingsService =
do_GetService("@mozilla.org/gfx/printsettings-service;1");
nsCOMPtr<nsIPrintSettings> printSettings;
if (printSettingsService) {
nsCOMPtr<nsIPrintSettings> printSettings;
printSettingsService->GetGlobalPrintSettings(
getter_AddRefs(printSettings));
@ -5223,9 +5223,6 @@ void nsGlobalWindowOuter::PrintOuter(ErrorResult& aError) {
EnterModalState();
webBrowserPrint->Print(printSettings, nullptr);
LeaveModalState();
} else {
webBrowserPrint->GetGlobalPrintSettings(getter_AddRefs(printSettings));
webBrowserPrint->Print(printSettings, nullptr);
}
}
#endif // NS_PRINTING