From 140deadc0cb8035c05aaabebe05d6aa6c5291829 Mon Sep 17 00:00:00 2001 From: Henrique Nakashima Date: Wed, 11 Jul 2018 21:40:03 +0000 Subject: Remove clunky mark property value getters by index. The key getters are necessary to list the properties, but after getting those keys, the *ByKey functions can be called. These functions are therefore unnecessary. In a follow-up CL, I will remove the "ByKey" suffix from the other versions. Bug: pdfium:1037 Change-Id: I02760025470a295971c4900fce1b6a8bbc7a5820 Reviewed-on: https://pdfium-review.googlesource.com/37590 Commit-Queue: Henrique Nakashima Reviewed-by: Lei Zhang --- fpdfsdk/fpdf_editpage.cpp | 33 --------------------------------- 1 file changed, 33 deletions(-) (limited to 'fpdfsdk/fpdf_editpage.cpp') diff --git a/fpdfsdk/fpdf_editpage.cpp b/fpdfsdk/fpdf_editpage.cpp index 8d8c315b07..968d857e8b 100644 --- a/fpdfsdk/fpdf_editpage.cpp +++ b/fpdfsdk/fpdf_editpage.cpp @@ -375,15 +375,6 @@ FPDFPageObjMark_GetParamKey(FPDF_PAGEOBJECTMARK mark, WideString::FromUTF8(param_pair->first.AsStringView()), buffer, buflen); } -FPDF_EXPORT FPDF_OBJECT_TYPE FPDF_CALLCONV -FPDFPageObjMark_GetParamValueType(FPDF_PAGEOBJECTMARK mark, - unsigned long index) { - auto* param_pair = GetMarkParamPairAtIndex(mark, index); - if (!param_pair) - return FPDF_OBJECT_UNKNOWN; - - return param_pair->second->GetType(); -} FPDF_EXPORT FPDF_OBJECT_TYPE FPDF_CALLCONV FPDFPageObjMark_GetParamValueTypeByKey(FPDF_PAGEOBJECTMARK mark, @@ -399,16 +390,6 @@ FPDFPageObjMark_GetParamValueTypeByKey(FPDF_PAGEOBJECTMARK mark, return pObject->GetType(); } -FPDF_EXPORT int FPDF_CALLCONV -FPDFPageObjMark_GetParamIntValue(FPDF_PAGEOBJECTMARK mark, - unsigned long index) { - auto* param_pair = GetMarkParamPairAtIndex(mark, index); - if (!param_pair) - return 0; - - return param_pair->second->GetInteger(); -} - FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFPageObjMark_GetParamIntValueByKey(FPDF_PAGEOBJECTMARK mark, FPDF_BYTESTRING key, @@ -425,20 +406,6 @@ FPDFPageObjMark_GetParamIntValueByKey(FPDF_PAGEOBJECTMARK mark, return true; } -FPDF_EXPORT unsigned long FPDF_CALLCONV -FPDFPageObjMark_GetParamStringValue(FPDF_PAGEOBJECTMARK mark, - unsigned long index, - void* buffer, - unsigned long buflen) { - auto* param_pair = GetMarkParamPairAtIndex(mark, index); - if (!param_pair) - return 0; - - return Utf16EncodeMaybeCopyAndReturnLength( - WideString::FromUTF8(param_pair->second->GetString().AsStringView()), - buffer, buflen); -} - FPDF_EXPORT FPDF_BOOL FPDF_CALLCONV FPDFPageObjMark_GetParamStringValueByKey(FPDF_PAGEOBJECTMARK mark, FPDF_BYTESTRING key, -- cgit v1.2.3