From 12a6b0c1bb3ab86a03a84464bed168995ae0d82a Mon Sep 17 00:00:00 2001 From: dsinclair Date: Thu, 26 May 2016 11:14:08 -0700 Subject: Remove FXJSE_HOBJECT and FXJSE_HVALUE for CFXJSE_Value* This CL replaces FXJSE_HOBJECT and FXJSE_HVALUE with the concrete CFXJSE_Value* type. All variables are renamed to match. Review-Url: https://codereview.chromium.org/2012253002 --- fpdfsdk/fpdfxfa/fpdfxfa_doc.cpp | 22 ++++++++-------------- 1 file changed, 8 insertions(+), 14 deletions(-) (limited to 'fpdfsdk/fpdfxfa/fpdfxfa_doc.cpp') diff --git a/fpdfsdk/fpdfxfa/fpdfxfa_doc.cpp b/fpdfsdk/fpdfxfa/fpdfxfa_doc.cpp index 701d999908..f207760398 100644 --- a/fpdfsdk/fpdfxfa/fpdfxfa_doc.cpp +++ b/fpdfsdk/fpdfxfa/fpdfxfa_doc.cpp @@ -1214,18 +1214,18 @@ FX_BOOL CPDFXFA_Document::_SubmitData(CXFA_FFDoc* hDoc, CXFA_Submit submit) { FX_BOOL CPDFXFA_Document::SetGlobalProperty(CXFA_FFDoc* hDoc, const CFX_ByteStringC& szPropName, - FXJSE_HVALUE hValue) { + CFXJSE_Value* pValue) { if (hDoc != m_pXFADoc) return FALSE; if (m_pSDKDoc && m_pSDKDoc->GetEnv()->GetJSRuntime()) - return m_pSDKDoc->GetEnv()->GetJSRuntime()->SetHValueByName(szPropName, - hValue); + return m_pSDKDoc->GetEnv()->GetJSRuntime()->SetValueByName(szPropName, + pValue); return FALSE; } FX_BOOL CPDFXFA_Document::GetPDFScriptObject(CXFA_FFDoc* hDoc, const CFX_ByteStringC& utf8Name, - FXJSE_HVALUE hValue) { + CFXJSE_Value* pValue) { if (hDoc != m_pXFADoc) return FALSE; @@ -1237,12 +1237,11 @@ FX_BOOL CPDFXFA_Document::GetPDFScriptObject(CXFA_FFDoc* hDoc, m_pJSContext = m_pSDKDoc->GetEnv()->GetJSRuntime()->NewContext(); } - return _GetHValueByName(utf8Name, hValue, - m_pSDKDoc->GetEnv()->GetJSRuntime()); + return m_pSDKDoc->GetEnv()->GetJSRuntime()->GetValueByName(utf8Name, pValue); } FX_BOOL CPDFXFA_Document::GetGlobalProperty(CXFA_FFDoc* hDoc, const CFX_ByteStringC& szPropName, - FXJSE_HVALUE hValue) { + CFXJSE_Value* pValue) { if (hDoc != m_pXFADoc) return FALSE; if (!m_pSDKDoc || !m_pSDKDoc->GetEnv()->GetJSRuntime()) @@ -1253,11 +1252,6 @@ FX_BOOL CPDFXFA_Document::GetGlobalProperty(CXFA_FFDoc* hDoc, m_pJSContext = m_pSDKDoc->GetEnv()->GetJSRuntime()->NewContext(); } - return _GetHValueByName(szPropName, hValue, - m_pSDKDoc->GetEnv()->GetJSRuntime()); -} -FX_BOOL CPDFXFA_Document::_GetHValueByName(const CFX_ByteStringC& utf8Name, - FXJSE_HVALUE hValue, - IJS_Runtime* runTime) { - return runTime->GetHValueByName(utf8Name, hValue); + return m_pSDKDoc->GetEnv()->GetJSRuntime()->GetValueByName(szPropName, + pValue); } -- cgit v1.2.3