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

Unified Diff: chrome/renderer/print_web_view_helper.cc

Issue 172115: Pass printing result to the browser.... (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: '' Created 11 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.cc
===================================================================
--- chrome/renderer/print_web_view_helper.cc (revision 25608)
+++ chrome/renderer/print_web_view_helper.cc (working copy)
@@ -29,7 +29,6 @@
WebFrame* frame,
WebView* web_view)
: frame_(frame), web_view_(web_view), expected_pages_count_(0) {
-
print_canvas_size_.set_width(
printing::ConvertUnit(print_params.printable_size.width(),
static_cast<int>(print_params.dpi),
@@ -114,33 +113,6 @@
return true;
}
-void PrintWebViewHelper::PrintPages(const ViewMsg_PrintPages_Params& params,
- WebFrame* frame) {
- PrepareFrameAndViewForPrint prep_frame_view(params.params,
- frame,
- frame->view());
- int page_count = prep_frame_view.GetExpectedPageCount();
-
- Send(new ViewHostMsg_DidGetPrintedPagesCount(routing_id(),
- params.params.document_cookie,
- page_count));
- if (page_count) {
- ViewMsg_PrintPage_Params page_params;
- page_params.params = params.params;
- if (params.pages.empty()) {
- for (int i = 0; i < page_count; ++i) {
- page_params.page_number = i;
- PrintPage(page_params, prep_frame_view.GetPrintCanvasSize(), frame);
- }
- } else {
- for (size_t i = 0; i < params.pages.size(); ++i) {
- page_params.page_number = params.pages[i];
- PrintPage(page_params, prep_frame_view.GetPrintCanvasSize(), frame);
- }
- }
- }
-}
-
void PrintWebViewHelper::PrintPageAsJPEG(
const ViewMsg_PrintPage_Params& params,
WebFrame* frame,

Powered by Google App Engine
This is Rietveld 408576698