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

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

Issue 821703005: Remove calls to deprecated SkPDFDevice and SkPDFDocuemnt. (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
« no previous file with comments | « no previous file | printing/pdf_metafile_skia.cc » ('j') | printing/pdf_metafile_skia.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/printing/print_web_view_helper.cc
diff --git a/chrome/renderer/printing/print_web_view_helper.cc b/chrome/renderer/printing/print_web_view_helper.cc
index 201e4c25cfc9c3bcd65485912053db37fa698538..8b4462084d5812f88106a4640b0426c5f1433732 100644
--- a/chrome/renderer/printing/print_web_view_helper.cc
+++ b/chrome/renderer/printing/print_web_view_helper.cc
@@ -533,18 +533,9 @@ float PrintWebViewHelper::RenderPageContent(blink::WebFrame* frame,
double scale_factor,
blink::WebCanvas* canvas) {
SkAutoCanvasRestore auto_restore(canvas, true);
- if (content_area != canvas_area) {
+ if (content_area.origin() != canvas_area.origin()) {
reed1 2014/12/22 20:41:24 If you like, you can skip this test and always cal
hal.canary 2014/12/23 15:19:14 Done.
canvas->translate((content_area.x() - canvas_area.x()) / scale_factor,
(content_area.y() - canvas_area.y()) / scale_factor);
- SkRect clip_rect(
- SkRect::MakeXYWH(content_area.origin().x() / scale_factor,
- content_area.origin().y() / scale_factor,
- content_area.size().width() / scale_factor,
- content_area.size().height() / scale_factor));
- SkIRect clip_int_rect;
- clip_rect.roundOut(&clip_int_rect);
- SkRegion clip_region(clip_int_rect);
- canvas->setClipRegion(clip_region);
}
return frame->printPage(page_number, canvas);
}
« no previous file with comments | « no previous file | printing/pdf_metafile_skia.cc » ('j') | printing/pdf_metafile_skia.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698