fix: Save As PDF from PDF Preview (#25959)

This commit is contained in:
Shelley Vohr 2020-10-16 18:30:46 -07:00 committed by GitHub
parent 708cf44d19
commit eca53aaaf1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 47 additions and 4 deletions

View file

@ -54,7 +54,6 @@
#endif
#if BUILDFLAG(ENABLE_PDF_VIEWER)
#include "chrome/renderer/pepper/chrome_pdf_print_client.h" // nogncheck
#include "shell/common/electron_constants.h"
#endif // BUILDFLAG(ENABLE_PDF_VIEWER)
@ -173,7 +172,8 @@ void RendererClientBase::RenderThreadStarted() {
#if BUILDFLAG(ENABLE_PDF_VIEWER)
// Enables printing from Chrome PDF viewer.
pdf::PepperPDFHost::SetPrintClient(new ChromePDFPrintClient());
pdf_print_client_.reset(new ChromePDFPrintClient());
pdf::PepperPDFHost::SetPrintClient(pdf_print_client_.get());
#endif
#if BUILDFLAG(ENABLE_BUILTIN_SPELLCHECKER)