Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(93)

Unified Diff: chrome/renderer/pepper/chrome_pdf_print_delegate.cc

Issue 505243003: pdf: Move PepperPDFHost into the pdf component. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@pdf-component
Patch Set: Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/renderer/pepper/chrome_pdf_print_delegate.cc
diff --git a/chrome/renderer/pepper/chrome_pdf_print_delegate.cc b/chrome/renderer/pepper/chrome_pdf_print_delegate.cc
index 59e692bd0bbe1bc86ad6e7c78384652ce11f70d1..04dd69878ca2adaba9a5718ed1c1439387413231 100644
--- a/chrome/renderer/pepper/chrome_pdf_print_delegate.cc
+++ b/chrome/renderer/pepper/chrome_pdf_print_delegate.cc
@@ -42,9 +42,12 @@ bool ChromePDFPrintDelegate::IsPrintingEnabled(PP_Instance instance_id) {
return helper && helper->IsPrintingEnabled();
}
-void ChromePDFPrintDelegate::Print(PP_Instance instance_id) {
+bool ChromePDFPrintDelegate::Print(PP_Instance instance_id) {
blink::WebElement element = GetWebElement(instance_id);
printing::PrintWebViewHelper* helper = GetPrintWebViewHelper(element);
- if (helper)
+ if (helper) {
helper->PrintNode(element);
+ return true;
+ }
+ return false;
}

Powered by Google App Engine
This is Rietveld 408576698