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

Unified Diff: printing/printed_document_win.cc

Issue 641923002: Change PDF scaling factor from double to float. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Review comments Created 6 years, 2 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
« no previous file with comments | « printing/printed_document.cc ('k') | printing/printed_page.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: printing/printed_document_win.cc
diff --git a/printing/printed_document_win.cc b/printing/printed_document_win.cc
index 5da1151634cad1d377b8b8a4b3c9c3620a1a3da4..3c6b7152ea1c0cd0c34ceedb59fa8d0b963366dd 100644
--- a/printing/printed_document_win.cc
+++ b/printing/printed_document_win.cc
@@ -16,11 +16,11 @@ namespace {
void SimpleModifyWorldTransform(HDC context,
int offset_x,
int offset_y,
- double shrink_factor) {
+ float shrink_factor) {
XFORM xform = { 0 };
xform.eDx = static_cast<float>(offset_x);
xform.eDy = static_cast<float>(offset_y);
- xform.eM11 = xform.eM22 = static_cast<float>(1. / shrink_factor);
+ xform.eM11 = xform.eM22 = 1.f / shrink_factor;
BOOL res = ModifyWorldTransform(context, &xform, MWT_LEFTMULTIPLY);
DCHECK_NE(res, 0);
}
« no previous file with comments | « printing/printed_document.cc ('k') | printing/printed_page.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698