summaryrefslogtreecommitdiff
path: root/fpdfsdk/cpdfsdk_interform.cpp
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2018-02-01 02:15:44 +0000
committerChromium commit bot <commit-bot@chromium.org>2018-02-01 02:15:44 +0000
commitf5ca90c00198c72488fd337ec8029a7f74b335b8 (patch)
tree8bd701cb4e662069470fc0ece5889823242f252e /fpdfsdk/cpdfsdk_interform.cpp
parent33c7ade187724c767fff74913cda63de182b0ce2 (diff)
downloadpdfium-f5ca90c00198c72488fd337ec8029a7f74b335b8.tar.xz
Rename some CJS / IJS names for clarity.
Prior cleanup before making FXJS/FXJSE share one v8 context. Return CJS object rather than isolate in one place. Use unique_ptr in one place. Change-Id: I837ae4880368a6d72e59b38f37e06908e05c34bd Reviewed-on: https://pdfium-review.googlesource.com/24950 Commit-Queue: dsinclair <dsinclair@chromium.org> Reviewed-by: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'fpdfsdk/cpdfsdk_interform.cpp')
-rw-r--r--fpdfsdk/cpdfsdk_interform.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/fpdfsdk/cpdfsdk_interform.cpp b/fpdfsdk/cpdfsdk_interform.cpp
index 3b76dca682..2d25894c5d 100644
--- a/fpdfsdk/cpdfsdk_interform.cpp
+++ b/fpdfsdk/cpdfsdk_interform.cpp
@@ -247,7 +247,7 @@ void CPDFSDK_InterForm::SynchronizeField(CPDF_FormField* pFormField) {
#endif // PDF_ENABLE_XFA
void CPDFSDK_InterForm::OnCalculate(CPDF_FormField* pFormField) {
- if (!m_pFormFillEnv->IsJSInitiated())
+ if (!m_pFormFillEnv->IsJSPlatformPresent())
return;
if (m_bBusy)
@@ -260,7 +260,7 @@ void CPDFSDK_InterForm::OnCalculate(CPDF_FormField* pFormField) {
return;
}
- IJS_Runtime* pRuntime = m_pFormFillEnv->GetJSRuntime();
+ IJS_Runtime* pRuntime = m_pFormFillEnv->GetIJSRuntime();
int nSize = m_pInterForm->CountFieldsInCalculationOrder();
for (int i = 0; i < nSize; i++) {
CPDF_FormField* pField = m_pInterForm->GetFieldInCalculationOrder(i);
@@ -301,12 +301,12 @@ void CPDFSDK_InterForm::OnCalculate(CPDF_FormField* pFormField) {
WideString CPDFSDK_InterForm::OnFormat(CPDF_FormField* pFormField,
bool& bFormatted) {
WideString sValue = pFormField->GetValue();
- if (!m_pFormFillEnv->IsJSInitiated()) {
+ if (!m_pFormFillEnv->IsJSPlatformPresent()) {
bFormatted = false;
return sValue;
}
- IJS_Runtime* pRuntime = m_pFormFillEnv->GetJSRuntime();
+ IJS_Runtime* pRuntime = m_pFormFillEnv->GetIJSRuntime();
if (pFormField->GetFieldType() == FormFieldType::kComboBox &&
pFormField->CountSelectedItems() > 0) {
int index = pFormField->GetSelectedIndex(0);