From bd56755ba86f2d87e24a3cee5cb92aa14a81bb27 Mon Sep 17 00:00:00 2001 From: tsepez Date: Tue, 29 Mar 2016 14:51:50 -0700 Subject: Rename GetElementValue() to GetDirectObject{By,At}(). Every time I read this code, I have to make the mental substituion that "Element value" means "de-ref indirect object", so it might as well just say so. BUG= Review URL: https://codereview.chromium.org/1841173002 --- core/fpdfdoc/doc_annot.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'core/fpdfdoc/doc_annot.cpp') diff --git a/core/fpdfdoc/doc_annot.cpp b/core/fpdfdoc/doc_annot.cpp index e6e441f237..1ea6c8b5a8 100644 --- a/core/fpdfdoc/doc_annot.cpp +++ b/core/fpdfdoc/doc_annot.cpp @@ -29,7 +29,7 @@ CPDF_AnnotList::CPDF_AnnotList(CPDF_Page* pPage) FX_BOOL bRegenerateAP = pAcroForm && pAcroForm->GetBooleanBy("NeedAppearances"); for (uint32_t i = 0; i < pAnnots->GetCount(); ++i) { - CPDF_Dictionary* pDict = ToDictionary(pAnnots->GetElementValue(i)); + CPDF_Dictionary* pDict = ToDictionary(pAnnots->GetDirectObjectAt(i)); if (!pDict) continue; @@ -166,7 +166,7 @@ CPDF_Stream* FPDFDOC_GetAnnotAP(CPDF_Dictionary* pAnnotDict, if (!pAP->KeyExist(ap_entry)) ap_entry = "N"; - CPDF_Object* psub = pAP->GetElementValue(ap_entry); + CPDF_Object* psub = pAP->GetDirectObjectBy(ap_entry); if (!psub) return nullptr; if (CPDF_Stream* pStream = psub->AsStream()) @@ -288,7 +288,7 @@ void CPDF_Annot::DrawBorder(CFX_RenderDevice* pDevice, int nLen = pDashArray->GetCount(); int i = 0; for (; i < nLen; ++i) { - CPDF_Object* pObj = pDashArray->GetElementValue(i); + CPDF_Object* pObj = pDashArray->GetDirectObjectAt(i); if (pObj && pObj->GetInteger()) { break; } -- cgit v1.2.3