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

Unified Diff: chrome/renderer/print_web_view_helper.h

Issue 7831041: Fix print preview workflow to reflect settings of selected printer. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Update per code review Created 9 years, 3 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/print_web_view_helper.h
diff --git a/chrome/renderer/print_web_view_helper.h b/chrome/renderer/print_web_view_helper.h
index 82d5e034e4548ade1936d77da43e6ac013fd40a3..dea51132e7cad08ccda8fc29cf27f6813b19c085 100644
--- a/chrome/renderer/print_web_view_helper.h
+++ b/chrome/renderer/print_web_view_helper.h
@@ -172,13 +172,10 @@ class PrintWebViewHelper : public RenderViewObserver,
// Print Settings -----------------------------------------------------------
// Initialize print page settings with default settings.
Lei Zhang 2011/09/21 03:56:04 You may want to add a comment to say InitPrintSett
arthurhsu 2011/09/22 00:01:26 Done.
- bool InitPrintSettings(WebKit::WebFrame* frame,
- WebKit::WebNode* node,
- bool is_preview);
+ bool InitPrintSettings(WebKit::WebFrame* frame);
- // Initialize print page settings with default settings and prepare the frame
- // for print. A new PrepareFrameAndViewForPrint is created to fulfill the
- // request and is filled into the |prepare| argument.
+ // Prepare the frame for print. A new PrepareFrameAndViewForPrint is created
+ // to fulfill the request and is filled into the |prepare| argument.
bool InitPrintSettingsAndPrepareFrame(
WebKit::WebFrame* frame,
WebKit::WebNode* node,
@@ -334,6 +331,7 @@ class PrintWebViewHelper : public RenderViewObserver,
PREVIEW_ERROR_MAC_DRAFT_METAFILE_INIT_FAILED,
PREVIEW_ERROR_PAGE_RENDERED_WITHOUT_METAFILE,
PREVIEW_ERROR_UPDATING_PRINT_SETTINGS,
+ PREVIEW_ERROR_INVALID_PRINTER_SETTINGS,
PREVIEW_ERROR_LAST_ENUM // Always last.
};
@@ -390,6 +388,7 @@ class PrintWebViewHelper : public RenderViewObserver,
printing::PreviewMetafile* metafile() const;
const PrintMsg_Print_Params& print_params() const;
const gfx::Size& GetPrintCanvasSize() const;
+ int last_error() const;
private:
enum State {

Powered by Google App Engine
This is Rietveld 408576698