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

Side by Side Diff: core/src/fpdfapi/fpdf_parser/fpdf_parser_objects.cpp

Issue 1158053003: kill IPDF_DocParser(). (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Explicit constructor. Created 5 years, 6 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 unified diff | Download patch
« no previous file with comments | « core/src/fpdfapi/fpdf_parser/fpdf_parser_document.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 PDFium Authors. All rights reserved. 1 // Copyright 2014 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6 6
7 #include "../../../include/fpdfapi/fpdf_parser.h" 7 #include "../../../include/fpdfapi/fpdf_parser.h"
8 #include "../../../include/fxcrt/fx_string.h" 8 #include "../../../include/fxcrt/fx_string.h"
9 9
10 //static 10 //static
(...skipping 1155 matching lines...) Expand 10 before | Expand all | Expand 10 after
1166 } 1166 }
1167 FX_LPBYTE p = FX_Alloc(FX_BYTE, m_dwSize); 1167 FX_LPBYTE p = FX_Alloc(FX_BYTE, m_dwSize);
1168 FXSYS_memcpy32(p, m_pData, m_dwSize); 1168 FXSYS_memcpy32(p, m_pData, m_dwSize);
1169 return p; 1169 return p;
1170 } 1170 }
1171 void CPDF_Reference::SetRef(CPDF_IndirectObjects* pDoc, FX_DWORD objnum) 1171 void CPDF_Reference::SetRef(CPDF_IndirectObjects* pDoc, FX_DWORD objnum)
1172 { 1172 {
1173 m_pObjList = pDoc; 1173 m_pObjList = pDoc;
1174 m_RefObjNum = objnum; 1174 m_RefObjNum = objnum;
1175 } 1175 }
1176 CPDF_IndirectObjects::CPDF_IndirectObjects(IPDF_DocParser* pParser) 1176 CPDF_IndirectObjects::CPDF_IndirectObjects(CPDF_Parser* pParser)
1177 { 1177 {
1178 m_pParser = pParser; 1178 m_pParser = pParser;
1179 m_IndirectObjs.InitHashTable(1013); 1179 m_IndirectObjs.InitHashTable(1013);
1180 if (pParser) { 1180 if (pParser) {
1181 m_LastObjNum = m_pParser->GetLastObjNum(); 1181 m_LastObjNum = m_pParser->GetLastObjNum();
1182 } else { 1182 } else {
1183 m_LastObjNum = 0; 1183 m_LastObjNum = 0;
1184 } 1184 }
1185 } 1185 }
1186 CPDF_IndirectObjects::~CPDF_IndirectObjects() 1186 CPDF_IndirectObjects::~CPDF_IndirectObjects()
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
1279 pObj->m_ObjNum = objnum; 1279 pObj->m_ObjNum = objnum;
1280 m_IndirectObjs.SetAt((FX_LPVOID)(FX_UINTPTR)objnum, pObj); 1280 m_IndirectObjs.SetAt((FX_LPVOID)(FX_UINTPTR)objnum, pObj);
1281 if (m_LastObjNum < objnum) { 1281 if (m_LastObjNum < objnum) {
1282 m_LastObjNum = objnum; 1282 m_LastObjNum = objnum;
1283 } 1283 }
1284 } 1284 }
1285 FX_DWORD CPDF_IndirectObjects::GetLastObjNum() const 1285 FX_DWORD CPDF_IndirectObjects::GetLastObjNum() const
1286 { 1286 {
1287 return m_LastObjNum; 1287 return m_LastObjNum;
1288 } 1288 }
OLDNEW
« no previous file with comments | « core/src/fpdfapi/fpdf_parser/fpdf_parser_document.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698