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

Unified Diff: core/src/fxge/win32/fx_win32_print.cpp

Issue 1727793002: Remove FXSYS_Div. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Rebase to master Created 4 years, 10 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 | « core/src/fxge/win32/fx_win32_gdipext.cpp ('k') | third_party/agg23/agg_clip_liang_barsky.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/src/fxge/win32/fx_win32_print.cpp
diff --git a/core/src/fxge/win32/fx_win32_print.cpp b/core/src/fxge/win32/fx_win32_print.cpp
index 4816c03e2c39e72056d743166f3cbcef375bb83c..6c262d83dc115dda55435d6ce6f884d4ec334456 100644
--- a/core/src/fxge/win32/fx_win32_print.cpp
+++ b/core/src/fxge/win32/fx_win32_print.cpp
@@ -149,8 +149,7 @@ static CFX_DIBitmap* Transform1bppBitmap(const CFX_DIBSource* pSrc,
uint8_t* src_buf = pSrcBitmap->GetBuffer();
FX_DWORD src_pitch = pSrcBitmap->GetPitch();
FX_FLOAT dest_area = pDestMatrix->GetUnitArea();
- FX_FLOAT area_scale =
- FXSYS_Div((FX_FLOAT)(src_width * src_height), dest_area);
+ FX_FLOAT area_scale = ((FX_FLOAT)(src_width * src_height)) / dest_area;
FX_FLOAT size_scale = FXSYS_sqrt(area_scale);
CFX_Matrix adjusted_matrix(*pDestMatrix);
adjusted_matrix.Scale(size_scale, size_scale);
« no previous file with comments | « core/src/fxge/win32/fx_win32_gdipext.cpp ('k') | third_party/agg23/agg_clip_liang_barsky.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698