diff --git a/web/app.js b/web/app.js index 1dae72e18..43c1c49f6 100644 --- a/web/app.js +++ b/web/app.js @@ -2210,10 +2210,9 @@ function webViewerPageMode({ mode }) { } function webViewerNamedAction(evt) { - // Processing couple of named actions that might be useful. - // See also PDFLinkService.executeNamedAction - const action = evt.action; - switch (action) { + // Processing a couple of named actions that might be useful, see also + // `PDFLinkService.executeNamedAction`. + switch (evt.action) { case "GoToPage": PDFViewerApplication.appConfig.toolbar.pageNumber.select(); break; @@ -2223,6 +2222,16 @@ function webViewerNamedAction(evt) { PDFViewerApplication.findBar.toggle(); } break; + + case "Print": + if (PDFViewerApplication.supportsPrinting) { + webViewerPrint(); + } + break; + + case "SaveAs": + webViewerSave(); + break; } }