summaryrefslogtreecommitdiff
path: root/core/fpdfapi/page/cpdf_form.cpp
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2018-05-14 20:13:40 +0000
committerChromium commit bot <commit-bot@chromium.org>2018-05-14 20:13:40 +0000
commita7ff4dc7c27c7940daec9cf740f4b7e7638a45ec (patch)
tree92fb866dde19233d7129486c453f6362780ed11b /core/fpdfapi/page/cpdf_form.cpp
parent77c223be193b303b833053a757a2f1f2534da610 (diff)
downloadpdfium-chromium/3431.tar.xz
Cleanup CPDF_Form parsing codechromium/3431
This CL folds the StartParse() method of CPDF_Form into the ParserContent method. The no arguments ParseContent is removed and ParseContentWithParams renamed to ParseContent. The callsites are updated to pass the nullptr's. Bug: chromium:813349 Change-Id: I304b77aef1de1b9aa20e4a3044db5023f5701584 Reviewed-on: https://pdfium-review.googlesource.com/32511 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'core/fpdfapi/page/cpdf_form.cpp')
-rw-r--r--core/fpdfapi/page/cpdf_form.cpp20
1 files changed, 5 insertions, 15 deletions
diff --git a/core/fpdfapi/page/cpdf_form.cpp b/core/fpdfapi/page/cpdf_form.cpp
index 3abeff4829..a63d3ce96d 100644
--- a/core/fpdfapi/page/cpdf_form.cpp
+++ b/core/fpdfapi/page/cpdf_form.cpp
@@ -29,12 +29,12 @@ CPDF_Form::CPDF_Form(CPDF_Document* pDoc,
LoadTransInfo();
}
-CPDF_Form::~CPDF_Form() {}
+CPDF_Form::~CPDF_Form() = default;
-void CPDF_Form::StartParse(CPDF_AllStates* pGraphicStates,
- const CFX_Matrix* pParentMatrix,
- CPDF_Type3Char* pType3Char,
- std::set<const uint8_t*>* parsedSet) {
+void CPDF_Form::ParseContent(CPDF_AllStates* pGraphicStates,
+ const CFX_Matrix* pParentMatrix,
+ CPDF_Type3Char* pType3Char,
+ std::set<const uint8_t*>* parsedSet) {
if (m_ParseState == CONTENT_PARSED || m_ParseState == CONTENT_PARSING)
return;
@@ -47,16 +47,6 @@ void CPDF_Form::StartParse(CPDF_AllStates* pGraphicStates,
m_pParser = pdfium::MakeUnique<CPDF_ContentParser>(
this, pGraphicStates, pParentMatrix, pType3Char, parsedSet);
m_ParseState = CONTENT_PARSING;
-}
-
-void CPDF_Form::ParseContent() {
- ParseContentWithParams(nullptr, nullptr, nullptr, nullptr);
-}
-void CPDF_Form::ParseContentWithParams(CPDF_AllStates* pGraphicStates,
- const CFX_Matrix* pParentMatrix,
- CPDF_Type3Char* pType3Char,
- std::set<const uint8_t*>* parsedSet) {
- StartParse(pGraphicStates, pParentMatrix, pType3Char, parsedSet);
ContinueParse(nullptr);
}