OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/renderer/print_web_view_helper.h" | 5 #include "chrome/renderer/print_web_view_helper.h" |
6 | 6 |
7 #include "app/l10n_util.h" | 7 #include "app/l10n_util.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/utf_string_conversions.h" | 9 #include "base/utf_string_conversions.h" |
10 #include "chrome/common/render_messages.h" | 10 #include "chrome/common/render_messages.h" |
| 11 #include "chrome/common/render_messages_params.h" |
11 #include "chrome/renderer/render_view.h" | 12 #include "chrome/renderer/render_view.h" |
12 #include "gfx/codec/jpeg_codec.h" | 13 #include "gfx/codec/jpeg_codec.h" |
13 #include "grit/generated_resources.h" | 14 #include "grit/generated_resources.h" |
14 #include "printing/units.h" | 15 #include "printing/units.h" |
15 #include "third_party/WebKit/WebKit/chromium/public/WebConsoleMessage.h" | 16 #include "third_party/WebKit/WebKit/chromium/public/WebConsoleMessage.h" |
16 #include "third_party/WebKit/WebKit/chromium/public/WebFrame.h" | 17 #include "third_party/WebKit/WebKit/chromium/public/WebFrame.h" |
17 #include "third_party/WebKit/WebKit/chromium/public/WebRect.h" | 18 #include "third_party/WebKit/WebKit/chromium/public/WebRect.h" |
18 #include "third_party/WebKit/WebKit/chromium/public/WebScreenInfo.h" | 19 #include "third_party/WebKit/WebKit/chromium/public/WebScreenInfo.h" |
19 #include "third_party/WebKit/WebKit/chromium/public/WebSize.h" | 20 #include "third_party/WebKit/WebKit/chromium/public/WebSize.h" |
20 #include "third_party/WebKit/WebKit/chromium/public/WebURLRequest.h" | 21 #include "third_party/WebKit/WebKit/chromium/public/WebURLRequest.h" |
(...skipping 431 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
452 static_cast<int>(content_width_in_points), | 453 static_cast<int>(content_width_in_points), |
453 static_cast<int>(content_height_in_points)); | 454 static_cast<int>(content_height_in_points)); |
454 #else | 455 #else |
455 params->printable_size = gfx::Size( | 456 params->printable_size = gfx::Size( |
456 static_cast<int>(ConvertUnitDouble( | 457 static_cast<int>(ConvertUnitDouble( |
457 content_width_in_points, printing::kPointsPerInch, params->dpi)), | 458 content_width_in_points, printing::kPointsPerInch, params->dpi)), |
458 static_cast<int>(ConvertUnitDouble( | 459 static_cast<int>(ConvertUnitDouble( |
459 content_height_in_points, printing::kPointsPerInch, params->dpi))); | 460 content_height_in_points, printing::kPointsPerInch, params->dpi))); |
460 #endif | 461 #endif |
461 } | 462 } |
OLD | NEW |