summaryrefslogtreecommitdiff
path: root/core/fpdfapi/fpdf_edit
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2016-03-25 13:42:34 -0700
committerTom Sepez <tsepez@chromium.org>2016-03-25 13:42:34 -0700
commit46c8b1e3202ab5ae3663141dc25bec3b4360322e (patch)
treec12b4979cf1bd8f2930175a986e6d7918e6b9c45 /core/fpdfapi/fpdf_edit
parent86a61dc374e8abe351df03a1aa6665013cc39345 (diff)
downloadpdfium-46c8b1e3202ab5ae3663141dc25bec3b4360322e.tar.xz
Replace CFX_DWordArray with CFX_ArrayTemplate<FX_DWORD>.
First step to getting rid of FX_DWORD. R=ochang@chromium.org Review URL: https://codereview.chromium.org/1832113003 .
Diffstat (limited to 'core/fpdfapi/fpdf_edit')
-rw-r--r--core/fpdfapi/fpdf_edit/editint.h4
-rw-r--r--core/fpdfapi/fpdf_edit/fpdf_edit_doc.cpp7
-rw-r--r--core/fpdfapi/fpdf_edit/include/cpdf_creator.h2
3 files changed, 7 insertions, 6 deletions
diff --git a/core/fpdfapi/fpdf_edit/editint.h b/core/fpdfapi/fpdf_edit/editint.h
index 8a73f123a3..eaf93d12da 100644
--- a/core/fpdfapi/fpdf_edit/editint.h
+++ b/core/fpdfapi/fpdf_edit/editint.h
@@ -29,14 +29,14 @@ class CPDF_ObjectStream {
FX_FILESIZE End(CPDF_Creator* pCreator);
- CFX_DWordArray m_ObjNumArray;
+ CFX_ArrayTemplate<FX_DWORD> m_ObjNumArray;
CFX_ByteTextBuf m_Buffer;
FX_DWORD m_dwObjNum;
int32_t m_index;
protected:
- CFX_DWordArray m_OffsetArray;
+ CFX_ArrayTemplate<FX_DWORD> m_OffsetArray;
};
class CPDF_XRefStream {
public:
diff --git a/core/fpdfapi/fpdf_edit/fpdf_edit_doc.cpp b/core/fpdfapi/fpdf_edit/fpdf_edit_doc.cpp
index cf79fdc47d..8e1072aa00 100644
--- a/core/fpdfapi/fpdf_edit/fpdf_edit_doc.cpp
+++ b/core/fpdfapi/fpdf_edit/fpdf_edit_doc.cpp
@@ -500,7 +500,8 @@ static void _CFString2CFXByteString(CFStringRef src, CFX_ByteString& dest) {
dest = (FX_CHAR*)pBuffer;
free(pBuffer);
}
-FX_BOOL IsHasCharSet(CFArrayRef languages, const CFX_DWordArray& charSets) {
+FX_BOOL IsHasCharSet(CFArrayRef languages,
+ const CFX_ArrayTemplate<FX_DWORD>& charSets) {
int iCount = charSets.GetSize();
for (int i = 0; i < CFArrayGetCount(languages); ++i) {
CFStringRef language = (CFStringRef)CFArrayGetValueAtIndex(languages, i);
@@ -571,7 +572,7 @@ CPDF_Font* CPDF_Document::AddMacFont(CTFontRef pFont,
CFRelease(descriptor);
return NULL;
}
- CFX_DWordArray charSets;
+ CFX_ArrayTemplate<FX_DWORD> charSets;
charSets.Add(FXFONT_CHINESEBIG5_CHARSET);
charSets.Add(FXFONT_GB2312_CHARSET);
charSets.Add(FXFONT_HANGEUL_CHARSET);
@@ -1075,7 +1076,7 @@ static int InsertDeletePDFPage(CPDF_Document* pDoc,
static int InsertNewPage(CPDF_Document* pDoc,
int iPage,
CPDF_Dictionary* pPageDict,
- CFX_DWordArray& pageList) {
+ CFX_ArrayTemplate<FX_DWORD>& pageList) {
CPDF_Dictionary* pRoot = pDoc->GetRoot();
if (!pRoot) {
return -1;
diff --git a/core/fpdfapi/fpdf_edit/include/cpdf_creator.h b/core/fpdfapi/fpdf_edit/include/cpdf_creator.h
index 0488266564..ad776a2866 100644
--- a/core/fpdfapi/fpdf_edit/include/cpdf_creator.h
+++ b/core/fpdfapi/fpdf_edit/include/cpdf_creator.h
@@ -93,7 +93,7 @@ class CPDF_Creator {
FX_POSITION m_Pos;
FX_FILESIZE m_XrefStart;
CFX_FileSizeListArray m_ObjectOffset;
- CFX_DWordArray m_NewObjNumArray;
+ CFX_ArrayTemplate<FX_DWORD> m_NewObjNumArray;
CPDF_Array* m_pIDArray;
int32_t m_FileVersion;
};