summaryrefslogtreecommitdiff
path: root/xfa/fxbarcode/qrcode/BC_QRDataBlock.cpp
diff options
context:
space:
mode:
authortsepez <tsepez@chromium.org>2016-04-28 14:56:27 -0700
committerCommit bot <commit-bot@chromium.org>2016-04-28 14:56:27 -0700
commitaef780db30c434e1d681d81852fb13160e72ed1e (patch)
tree24810c630b3b27649c0dd856d795c0069ca5bcd6 /xfa/fxbarcode/qrcode/BC_QRDataBlock.cpp
parent8e957baa851aed4b02511d04a66c0f95387d1e10 (diff)
downloadpdfium-aef780db30c434e1d681d81852fb13160e72ed1e.tar.xz
Replace CFX_PtrArray with typesafe CFX_ArrayTemplate, part 4
Review-Url: https://codereview.chromium.org/1932703003
Diffstat (limited to 'xfa/fxbarcode/qrcode/BC_QRDataBlock.cpp')
-rw-r--r--xfa/fxbarcode/qrcode/BC_QRDataBlock.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/xfa/fxbarcode/qrcode/BC_QRDataBlock.cpp b/xfa/fxbarcode/qrcode/BC_QRDataBlock.cpp
index 9805ac9af8..721301cccc 100644
--- a/xfa/fxbarcode/qrcode/BC_QRDataBlock.cpp
+++ b/xfa/fxbarcode/qrcode/BC_QRDataBlock.cpp
@@ -52,16 +52,16 @@ CFX_PtrArray* CBC_QRDataBlock::GetDataBlocks(
}
CBC_QRCoderECBlocks* ecBlocks = version->GetECBlocksForLevel(ecLevel);
int32_t totalBlocks = 0;
- CFX_PtrArray* ecBlockArray = ecBlocks->GetECBlocks();
+ CFX_ArrayTemplate<CBC_QRCoderECB*>* ecBlockArray = ecBlocks->GetECBlocks();
int32_t i = 0;
for (i = 0; i < ecBlockArray->GetSize(); i++) {
- totalBlocks += ((CBC_QRCoderECB*)(*ecBlockArray)[i])->GetCount();
+ totalBlocks += (*ecBlockArray)[i]->GetCount();
}
std::unique_ptr<CFX_PtrArray> result(new CFX_PtrArray());
result->SetSize(totalBlocks);
int32_t numResultBlocks = 0;
for (int32_t j = 0; j < ecBlockArray->GetSize(); j++) {
- CBC_QRCoderECB* ecBlock = (CBC_QRCoderECB*)(*ecBlockArray)[j];
+ CBC_QRCoderECB* ecBlock = (*ecBlockArray)[j];
for (int32_t k = 0; k < ecBlock->GetCount(); k++) {
int32_t numDataCodewords = ecBlock->GetDataCodeWords();
int32_t numBlockCodewords =