diff options
author | Dan Sinclair <dsinclair@chromium.org> | 2017-03-14 14:43:42 -0400 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2017-03-14 19:05:58 +0000 |
commit | 05df075154a832fcb476e1dfcfb865722d0ea898 (patch) | |
tree | b8b771b62adae74d5d5ee561db75d10de3a848bf /xfa/fxbarcode/datamatrix | |
parent | 6b94f01d1c8ad386d497428c7397b1a99614aeba (diff) | |
download | pdfium-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 'xfa/fxbarcode/datamatrix')
-rw-r--r-- | xfa/fxbarcode/datamatrix/BC_HighLevelEncoder.cpp | 10 | ||||
-rw-r--r-- | xfa/fxbarcode/datamatrix/BC_HighLevelEncoder.h | 2 |
2 files changed, 5 insertions, 7 deletions
diff --git a/xfa/fxbarcode/datamatrix/BC_HighLevelEncoder.cpp b/xfa/fxbarcode/datamatrix/BC_HighLevelEncoder.cpp index ec6eb02b1c..90877c7ef3 100644 --- a/xfa/fxbarcode/datamatrix/BC_HighLevelEncoder.cpp +++ b/xfa/fxbarcode/datamatrix/BC_HighLevelEncoder.cpp @@ -140,7 +140,7 @@ int32_t CBC_HighLevelEncoder::lookAheadTest(CFX_WideString msg, if (startpos >= msg.GetLength()) { return currentMode; } - std::vector<FX_FLOAT> charCounts; + std::vector<float> charCounts; if (currentMode == ASCII_ENCODATION) { charCounts.push_back(0); charCounts.push_back(1); @@ -189,12 +189,10 @@ int32_t CBC_HighLevelEncoder::lookAheadTest(CFX_WideString msg, if (isDigit(c)) { charCounts[ASCII_ENCODATION] += 0.5; } else if (isExtendedASCII(c)) { - charCounts[ASCII_ENCODATION] = - (FX_FLOAT)ceil(charCounts[ASCII_ENCODATION]); + charCounts[ASCII_ENCODATION] = (float)ceil(charCounts[ASCII_ENCODATION]); charCounts[ASCII_ENCODATION] += 2; } else { - charCounts[ASCII_ENCODATION] = - (FX_FLOAT)ceil(charCounts[ASCII_ENCODATION]); + charCounts[ASCII_ENCODATION] = (float)ceil(charCounts[ASCII_ENCODATION]); charCounts[ASCII_ENCODATION]++; } if (isNativeC40(c)) { @@ -320,7 +318,7 @@ wchar_t CBC_HighLevelEncoder::randomize253State(wchar_t ch, : (wchar_t)(tempVariable - 254); } int32_t CBC_HighLevelEncoder::findMinimums( - std::vector<FX_FLOAT>& charCounts, + std::vector<float>& charCounts, CFX_ArrayTemplate<int32_t>& intCharCounts, int32_t min, CFX_ArrayTemplate<uint8_t>& mins) { diff --git a/xfa/fxbarcode/datamatrix/BC_HighLevelEncoder.h b/xfa/fxbarcode/datamatrix/BC_HighLevelEncoder.h index cfd16ed676..821dedd29f 100644 --- a/xfa/fxbarcode/datamatrix/BC_HighLevelEncoder.h +++ b/xfa/fxbarcode/datamatrix/BC_HighLevelEncoder.h @@ -63,7 +63,7 @@ class CBC_HighLevelEncoder : public CBC_SymbolShapeHint { private: static wchar_t randomize253State(wchar_t ch, int32_t codewordPosition); - static int32_t findMinimums(std::vector<FX_FLOAT>& charCounts, + static int32_t findMinimums(std::vector<float>& charCounts, CFX_ArrayTemplate<int32_t>& intCharCounts, int32_t min, CFX_ArrayTemplate<uint8_t>& mins); |