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

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

Issue 2508923003: Make printing work better with OOPIF. (try 2) (Closed)
Patch Set: Fix android_webview Created 4 years, 1 month 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_client.cc
diff --git a/chrome/renderer/pepper/chrome_pdf_print_client.cc b/chrome/renderer/pepper/chrome_pdf_print_client.cc
index f3e6528daca4c2c12a93a2be5af48fb65e3a5c85..4085c1025c1677e0ffbdf34e2bfcca60ec90d394 100644
--- a/chrome/renderer/pepper/chrome_pdf_print_client.cc
+++ b/chrome/renderer/pepper/chrome_pdf_print_client.cc
@@ -6,7 +6,7 @@
#include "components/printing/renderer/print_web_view_helper.h"
#include "content/public/renderer/pepper_plugin_instance.h"
-#include "content/public/renderer/render_view.h"
+#include "content/public/renderer/render_frame.h"
#include "third_party/WebKit/public/web/WebDocument.h"
#include "third_party/WebKit/public/web/WebElement.h"
#include "third_party/WebKit/public/web/WebLocalFrame.h"
@@ -26,14 +26,15 @@ printing::PrintWebViewHelper* GetPrintWebViewHelper(
const blink::WebElement& element) {
if (element.isNull())
return nullptr;
- blink::WebView* view = element.document().frame()->view();
- content::RenderView* render_view = content::RenderView::FromWebView(view);
- return printing::PrintWebViewHelper::Get(render_view);
+ auto* render_frame =
+ content::RenderFrame::FromWebFrame(element.document().frame());
+ return printing::PrintWebViewHelper::Get(render_frame);
}
} // namespace
ChromePDFPrintClient::ChromePDFPrintClient() {}
+
ChromePDFPrintClient::~ChromePDFPrintClient() {}
bool ChromePDFPrintClient::IsPrintingEnabled(PP_Instance instance_id) {
« no previous file with comments | « chrome/renderer/chrome_render_frame_observer.cc ('k') | chrome/renderer/printing/chrome_print_web_view_helper_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698