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

Unified Diff: xfa/fxbarcode/pdf417/BC_PDF417DetectorResult.cpp

Issue 1936733002: Replace CFX_PtrArray with typesafe CFX_ArrayTemplate, part 10 (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Nits Created 4 years, 8 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 | « xfa/fxbarcode/pdf417/BC_PDF417DetectorResult.h ('k') | xfa/fxbarcode/pdf417/BC_PDF417ECModulusPoly.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: xfa/fxbarcode/pdf417/BC_PDF417DetectorResult.cpp
diff --git a/xfa/fxbarcode/pdf417/BC_PDF417DetectorResult.cpp b/xfa/fxbarcode/pdf417/BC_PDF417DetectorResult.cpp
index 557d50d9518507afe4f54e35d87300e95de160a7..4b68bdf6788a1430a7aa590cb5c7be62f566c18f 100644
--- a/xfa/fxbarcode/pdf417/BC_PDF417DetectorResult.cpp
+++ b/xfa/fxbarcode/pdf417/BC_PDF417DetectorResult.cpp
@@ -24,27 +24,25 @@
#include "xfa/fxbarcode/common/BC_CommonBitMatrix.h"
#include "xfa/fxbarcode/pdf417/BC_PDF417DetectorResult.h"
-CBC_PDF417DetectorResult::CBC_PDF417DetectorResult(CBC_CommonBitMatrix* bits,
- CFX_PtrArray* points) {
- m_bits = bits;
- m_points = points;
-}
+CBC_PDF417DetectorResult::CBC_PDF417DetectorResult(
+ CBC_CommonBitMatrix* bits,
+ CBC_ResultPointArrayArray* points)
+ : m_bits(bits), m_points(points) {}
+
CBC_PDF417DetectorResult::~CBC_PDF417DetectorResult() {
for (int32_t i = 0; i < m_points->GetSize(); i++) {
- CFX_PtrArray* temp = (CFX_PtrArray*)m_points->GetAt(i);
- for (int32_t j = 0; j < temp->GetSize(); j++) {
- delete (CBC_ResultPoint*)temp->GetAt(j);
- }
- temp->RemoveAll();
+ CBC_ResultPointArray* temp = m_points->GetAt(i);
+ for (int32_t j = 0; j < temp->GetSize(); j++)
+ delete temp->GetAt(j);
+
delete temp;
}
- m_points->RemoveAll();
- delete m_points;
}
-CBC_CommonBitMatrix* CBC_PDF417DetectorResult::getBits() {
+
+CBC_CommonBitMatrix* CBC_PDF417DetectorResult::getBits() const {
return m_bits;
}
-CFX_PtrArray* CBC_PDF417DetectorResult::getPoints() {
- return m_points;
+CBC_ResultPointArrayArray* CBC_PDF417DetectorResult::getPoints() const {
+ return m_points.get();
}
« no previous file with comments | « xfa/fxbarcode/pdf417/BC_PDF417DetectorResult.h ('k') | xfa/fxbarcode/pdf417/BC_PDF417ECModulusPoly.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698