summaryrefslogtreecommitdiff
path: root/xfa/fxbarcode/oned/BC_OnedCode128Writer.cpp
diff options
context:
space:
mode:
authortsepez <tsepez@chromium.org>2016-11-02 15:43:18 -0700
committerCommit bot <commit-bot@chromium.org>2016-11-02 15:43:19 -0700
commitd19e912dd469e4bdad9f3020e1f6eb98f10f3470 (patch)
tree239cb568a80445f14a1ab9b63dcaaddcce67e1cc /xfa/fxbarcode/oned/BC_OnedCode128Writer.cpp
parent12f3e4a58f05850b93af35619cb04f0231d86acc (diff)
downloadpdfium-d19e912dd469e4bdad9f3020e1f6eb98f10f3470.tar.xz
Remove FX_BOOL from xfa.
Review-Url: https://codereview.chromium.org/2467203003
Diffstat (limited to 'xfa/fxbarcode/oned/BC_OnedCode128Writer.cpp')
-rw-r--r--xfa/fxbarcode/oned/BC_OnedCode128Writer.cpp24
1 files changed, 12 insertions, 12 deletions
diff --git a/xfa/fxbarcode/oned/BC_OnedCode128Writer.cpp b/xfa/fxbarcode/oned/BC_OnedCode128Writer.cpp
index 109742e85f..ed2d2c1b24 100644
--- a/xfa/fxbarcode/oned/BC_OnedCode128Writer.cpp
+++ b/xfa/fxbarcode/oned/BC_OnedCode128Writer.cpp
@@ -80,22 +80,22 @@ CBC_OnedCode128Writer::~CBC_OnedCode128Writer() {}
BC_TYPE CBC_OnedCode128Writer::GetType() {
return m_codeFormat;
}
-FX_BOOL CBC_OnedCode128Writer::CheckContentValidity(
+bool CBC_OnedCode128Writer::CheckContentValidity(
const CFX_WideStringC& contents) {
- FX_BOOL ret = TRUE;
+ bool ret = true;
int32_t position = 0;
int32_t patternIndex = -1;
if (m_codeFormat == BC_CODE128_B || m_codeFormat == BC_CODE128_C) {
while (position < contents.GetLength()) {
patternIndex = (int32_t)contents.GetAt(position);
if (patternIndex < 32 || patternIndex > 126 || patternIndex == 34) {
- ret = FALSE;
+ ret = false;
break;
}
position++;
}
} else {
- ret = FALSE;
+ ret = false;
}
return ret;
}
@@ -135,12 +135,12 @@ CFX_WideString CBC_OnedCode128Writer::FilterContents(
}
return filtercontents;
}
-FX_BOOL CBC_OnedCode128Writer::SetTextLocation(BC_TEXT_LOC location) {
+bool CBC_OnedCode128Writer::SetTextLocation(BC_TEXT_LOC location) {
if (location < BC_TEXT_LOC_NONE || location > BC_TEXT_LOC_BELOWEMBED) {
- return FALSE;
+ return false;
}
m_locTextLoc = location;
- return TRUE;
+ return true;
}
uint8_t* CBC_OnedCode128Writer::Encode(const CFX_ByteString& contents,
BCFORMAT format,
@@ -166,16 +166,16 @@ uint8_t* CBC_OnedCode128Writer::Encode(const CFX_ByteString& contents,
BC_EXCEPTION_CHECK_ReturnValue(e, nullptr);
return ret;
}
-FX_BOOL CBC_OnedCode128Writer::IsDigits(const CFX_ByteString& contents,
- int32_t start,
- int32_t length) {
+bool CBC_OnedCode128Writer::IsDigits(const CFX_ByteString& contents,
+ int32_t start,
+ int32_t length) {
int32_t end = start + length;
for (int32_t i = start; i < end; i++) {
if (contents[i] < '0' || contents[i] > '9') {
- return FALSE;
+ return false;
}
}
- return TRUE;
+ return true;
}
uint8_t* CBC_OnedCode128Writer::Encode(const CFX_ByteString& contents,