diff options
-rw-r--r-- | core/fpdfdoc/cpdf_actionfields.cpp | 27 | ||||
-rw-r--r-- | core/fpdfdoc/cpdf_actionfields.h | 1 |
2 files changed, 1 insertions, 27 deletions
diff --git a/core/fpdfdoc/cpdf_actionfields.cpp b/core/fpdfdoc/cpdf_actionfields.cpp index 89636bfc23..2af70c2be5 100644 --- a/core/fpdfdoc/cpdf_actionfields.cpp +++ b/core/fpdfdoc/cpdf_actionfields.cpp @@ -13,32 +13,7 @@ CPDF_ActionFields::CPDF_ActionFields(const CPDF_Action* pAction) : m_pAction(pAction) {} -CPDF_ActionFields::~CPDF_ActionFields() {} - -size_t CPDF_ActionFields::GetFieldsCount() const { - if (!m_pAction) - return 0; - - const CPDF_Dictionary* pDict = m_pAction->GetDict(); - if (!pDict) - return 0; - - ByteString csType = pDict->GetStringFor("S"); - const CPDF_Object* pFields; - if (csType == "Hide") - pFields = pDict->GetDirectObjectFor("T"); - else - pFields = pDict->GetArrayFor("Fields"); - - if (!pFields) - return 0; - if (pFields->IsDictionary()) - return 1; - if (pFields->IsString()) - return 1; - const CPDF_Array* pArray = pFields->AsArray(); - return pArray ? pArray->GetCount() : 0; -} +CPDF_ActionFields::~CPDF_ActionFields() = default; std::vector<const CPDF_Object*> CPDF_ActionFields::GetAllFields() const { std::vector<const CPDF_Object*> fields; diff --git a/core/fpdfdoc/cpdf_actionfields.h b/core/fpdfdoc/cpdf_actionfields.h index affc03cfec..1306a4c08d 100644 --- a/core/fpdfdoc/cpdf_actionfields.h +++ b/core/fpdfdoc/cpdf_actionfields.h @@ -21,7 +21,6 @@ class CPDF_ActionFields { explicit CPDF_ActionFields(const CPDF_Action* pAction); ~CPDF_ActionFields(); - size_t GetFieldsCount() const; std::vector<const CPDF_Object*> GetAllFields() const; const CPDF_Object* GetField(size_t iIndex) const; |