summaryrefslogtreecommitdiff
path: root/fpdfsdk/fpdf_flatten.cpp
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2017-03-14 14:43:42 -0400
committerChromium commit bot <commit-bot@chromium.org>2017-03-14 19:05:58 +0000
commit05df075154a832fcb476e1dfcfb865722d0ea898 (patch)
treeb8b771b62adae74d5d5ee561db75d10de3a848bf /fpdfsdk/fpdf_flatten.cpp
parent6b94f01d1c8ad386d497428c7397b1a99614aeba (diff)
downloadpdfium-05df075154a832fcb476e1dfcfb865722d0ea898.tar.xz
Replace FX_FLOAT with underlying float type.
Change-Id: I158b7d80b0ec28b742a9f2d5a96f3dde7fb3ab56 Reviewed-on: https://pdfium-review.googlesource.com/3031 Commit-Queue: dsinclair <dsinclair@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org> Reviewed-by: Nicolás Peña <npm@chromium.org>
Diffstat (limited to 'fpdfsdk/fpdf_flatten.cpp')
-rw-r--r--fpdfsdk/fpdf_flatten.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/fpdfsdk/fpdf_flatten.cpp b/fpdfsdk/fpdf_flatten.cpp
index 06ea939b72..c43412cfc7 100644
--- a/fpdfsdk/fpdf_flatten.cpp
+++ b/fpdfsdk/fpdf_flatten.cpp
@@ -123,14 +123,14 @@ int ParserAnnots(CPDF_Document* pSourceDoc,
return FLATTEN_SUCCESS;
}
-FX_FLOAT GetMinMaxValue(const std::vector<CFX_FloatRect>& array,
- FPDF_TYPE type,
- FPDF_VALUE value) {
+float GetMinMaxValue(const std::vector<CFX_FloatRect>& array,
+ FPDF_TYPE type,
+ FPDF_VALUE value) {
size_t nRects = array.size();
if (nRects <= 0)
return 0.0f;
- std::vector<FX_FLOAT> pArray(nRects);
+ std::vector<float> pArray(nRects);
switch (value) {
case LEFT:
for (size_t i = 0; i < nRects; i++)
@@ -153,7 +153,7 @@ FX_FLOAT GetMinMaxValue(const std::vector<CFX_FloatRect>& array,
return 0.0f;
}
- FX_FLOAT fRet = pArray[0];
+ float fRet = pArray[0];
if (type == MAX) {
for (size_t i = 1; i < nRects; i++)
fRet = std::max(fRet, pArray[i]);
@@ -231,11 +231,11 @@ CFX_Matrix GetMatrix(CFX_FloatRect rcAnnot,
matrix.TransformRect(rcStream);
rcStream.Normalize();
- FX_FLOAT a = rcAnnot.Width() / rcStream.Width();
- FX_FLOAT d = rcAnnot.Height() / rcStream.Height();
+ float a = rcAnnot.Width() / rcStream.Width();
+ float d = rcAnnot.Height() / rcStream.Height();
- FX_FLOAT e = rcAnnot.left - rcStream.left * a;
- FX_FLOAT f = rcAnnot.bottom - rcStream.bottom * d;
+ float e = rcAnnot.left - rcStream.left * a;
+ float f = rcAnnot.bottom - rcStream.bottom * d;
return CFX_Matrix(a, 0, 0, d, e, f);
}