diff options
Diffstat (limited to 'fpdfsdk/fpdfxfa/cpdfxfa_docenvironment.cpp')
-rw-r--r-- | fpdfsdk/fpdfxfa/cpdfxfa_docenvironment.cpp | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/fpdfsdk/fpdfxfa/cpdfxfa_docenvironment.cpp b/fpdfsdk/fpdfxfa/cpdfxfa_docenvironment.cpp index 8c89895292..6cf4bff833 100644 --- a/fpdfsdk/fpdfxfa/cpdfxfa_docenvironment.cpp +++ b/fpdfsdk/fpdfxfa/cpdfxfa_docenvironment.cpp @@ -380,14 +380,16 @@ void CPDFXFA_DocEnvironment::SetCurrentPage(CXFA_FFDoc* hDoc, bool CPDFXFA_DocEnvironment::IsCalculationsEnabled(CXFA_FFDoc* hDoc) { if (hDoc != m_pContext->GetXFADoc() || !m_pContext->GetFormFillEnv()) return false; - return m_pContext->GetFormFillEnv()->GetInterForm()->IsXfaCalculateEnabled(); + auto* pForm = m_pContext->GetFormFillEnv()->GetInteractiveForm(); + return pForm->IsXfaCalculateEnabled(); } void CPDFXFA_DocEnvironment::SetCalculationsEnabled(CXFA_FFDoc* hDoc, bool bEnabled) { if (hDoc != m_pContext->GetXFADoc() || !m_pContext->GetFormFillEnv()) return; - m_pContext->GetFormFillEnv()->GetInterForm()->XfaEnableCalculate(bEnabled); + m_pContext->GetFormFillEnv()->GetInteractiveForm()->XfaEnableCalculate( + bEnabled); } void CPDFXFA_DocEnvironment::GetTitle(CXFA_FFDoc* hDoc, WideString& wsTitle) { @@ -528,8 +530,9 @@ void CPDFXFA_DocEnvironment::GotoURL(CXFA_FFDoc* hDoc, bool CPDFXFA_DocEnvironment::IsValidationsEnabled(CXFA_FFDoc* hDoc) { if (hDoc != m_pContext->GetXFADoc() || !m_pContext->GetFormFillEnv()) return false; - auto* pInterform = m_pContext->GetFormFillEnv()->GetInterForm(); - return pInterform->IsXfaValidationsEnabled(); + + auto* pForm = m_pContext->GetFormFillEnv()->GetInteractiveForm(); + return pForm->IsXfaValidationsEnabled(); } void CPDFXFA_DocEnvironment::SetValidationsEnabled(CXFA_FFDoc* hDoc, @@ -537,7 +540,7 @@ void CPDFXFA_DocEnvironment::SetValidationsEnabled(CXFA_FFDoc* hDoc, if (hDoc != m_pContext->GetXFADoc() || !m_pContext->GetFormFillEnv()) return; - m_pContext->GetFormFillEnv()->GetInterForm()->XfaSetValidationsEnabled( + m_pContext->GetFormFillEnv()->GetInteractiveForm()->XfaSetValidationsEnabled( bEnabled); } @@ -592,10 +595,10 @@ FX_ARGB CPDFXFA_DocEnvironment::GetHighlightColor(CXFA_FFDoc* hDoc) { if (hDoc != m_pContext->GetXFADoc() || !m_pContext->GetFormFillEnv()) return 0; - CPDFSDK_InterForm* pInterForm = m_pContext->GetFormFillEnv()->GetInterForm(); - return AlphaAndColorRefToArgb( - pInterForm->GetHighlightAlpha(), - pInterForm->GetHighlightColor(FormFieldType::kXFA)); + CPDFSDK_InteractiveForm* pForm = + m_pContext->GetFormFillEnv()->GetInteractiveForm(); + return AlphaAndColorRefToArgb(pForm->GetHighlightAlpha(), + pForm->GetHighlightColor(FormFieldType::kXFA)); } #ifdef PDF_XFA_ELEMENT_SUBMIT_ENABLED |