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

Unified Diff: chrome/renderer/printing/print_web_view_helper.h

Issue 791133006: Delegates for the printing component (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years 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/printing/print_web_view_helper.h
diff --git a/chrome/renderer/printing/print_web_view_helper.h b/chrome/renderer/printing/print_web_view_helper.h
index f144adc45d02b52059541420eb40cbd3c5d76e8d..b7a0bd92e6893e105fe7a3381712451d1bb65d37 100644
--- a/chrome/renderer/printing/print_web_view_helper.h
+++ b/chrome/renderer/printing/print_web_view_helper.h
@@ -39,6 +39,7 @@ namespace printing {
struct PageSizeMargins;
class PrepareFrameAndViewForPrint;
+class PrintWebViewHelperDelegate;
// Stores reference to frame using WebVew and unique name.
// Workaround to modal dialog issue on Linux. crbug.com/236147.
@@ -66,7 +67,8 @@ class PrintWebViewHelper
: public content::RenderViewObserver,
public content::RenderViewObserverTracker<PrintWebViewHelper> {
public:
- explicit PrintWebViewHelper(content::RenderView* render_view);
+ explicit PrintWebViewHelper(content::RenderView* render_view,
+ scoped_ptr<PrintWebViewHelperDelegate> delegate);
~PrintWebViewHelper() override;
// Disable print preview and switch to system dialog printing even if full
@@ -327,6 +329,8 @@ class PrintWebViewHelper
// True, when printing from print preview.
bool print_for_preview_;
+ scoped_ptr<PrintWebViewHelperDelegate> delegate_;
+
// Keeps track of the state of print preview between messages.
// TODO(vitalybuka): Create PrintPreviewContext when needed and delete after
// use. Now it's interaction with various messages is confusing.

Powered by Google App Engine
This is Rietveld 408576698