summaryrefslogtreecommitdiff
path: root/fxjs/cfxjse_engine.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'fxjs/cfxjse_engine.cpp')
-rw-r--r--fxjs/cfxjse_engine.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/fxjs/cfxjse_engine.cpp b/fxjs/cfxjse_engine.cpp
index e5d6c0a0fe..c2dba2f311 100644
--- a/fxjs/cfxjse_engine.cpp
+++ b/fxjs/cfxjse_engine.cpp
@@ -130,7 +130,7 @@ CFXJSE_Engine::CFXJSE_Engine(CXFA_Document* pDocument, v8::Isolate* pIsolate)
pDocument->GetRoot())),
m_pIsolate(pIsolate),
m_pJsClass(nullptr),
- m_eScriptType(XFA_ScriptDataType::Unknown),
+ m_eScriptType(CXFA_ScriptData::Type::Unknown),
m_pScriptNodeArray(nullptr),
m_ResolveProcessor(pdfium::MakeUnique<CFXJSE_ResolveProcessor>()),
m_pThisObject(nullptr),
@@ -150,14 +150,14 @@ CFXJSE_Engine::~CFXJSE_Engine() {
delete ToThisProxy(pair.second->GetGlobalObject().get(), nullptr);
}
-bool CFXJSE_Engine::RunScript(XFA_ScriptDataType eScriptType,
+bool CFXJSE_Engine::RunScript(CXFA_ScriptData::Type eScriptType,
const WideStringView& wsScript,
CFXJSE_Value* hRetValue,
CXFA_Object* pThisObject) {
ByteString btScript;
- AutoRestorer<XFA_ScriptDataType> typeRestorer(&m_eScriptType);
+ AutoRestorer<CXFA_ScriptData::Type> typeRestorer(&m_eScriptType);
m_eScriptType = eScriptType;
- if (eScriptType == XFA_ScriptDataType::Formcalc) {
+ if (eScriptType == CXFA_ScriptData::Type::Formcalc) {
if (!m_FM2JSContext) {
m_FM2JSContext = pdfium::MakeUnique<CFXJSE_FormCalcContext>(
m_pIsolate, m_JsContext.get(), m_pDocument.Get());
@@ -243,7 +243,7 @@ void CFXJSE_Engine::GlobalPropertyGetter(CFXJSE_Value* pObject,
CFXJSE_Engine* lpScriptContext = pDoc->GetScriptContext();
CXFA_Object* lpCurNode = lpScriptContext->GetVariablesThis(pOriginalObject);
WideString wsPropName = WideString::FromUTF8(szPropName);
- if (lpScriptContext->GetType() == XFA_ScriptDataType::Formcalc) {
+ if (lpScriptContext->GetType() == CXFA_ScriptData::Type::Formcalc) {
if (szPropName == kFormCalcRuntime) {
lpScriptContext->m_FM2JSContext->GlobalPropertyGetter(pValue);
return;
@@ -319,7 +319,7 @@ void CFXJSE_Engine::NormalPropertyGetter(CFXJSE_Value* pOriginalValue,
return;
if (pObject == lpScriptContext->GetThisObject() ||
- (lpScriptContext->GetType() == XFA_ScriptDataType::Javascript &&
+ (lpScriptContext->GetType() == CXFA_ScriptData::Type::Javascript &&
!lpScriptContext->IsStrictScopeInJavaScript())) {
dwFlag = XFA_RESOLVENODE_Parent | XFA_RESOLVENODE_Siblings;
bRet = lpScriptContext->QueryNodeByFlag(ToNode(pObject),
@@ -454,7 +454,7 @@ bool CFXJSE_Engine::IsStrictScopeInJavaScript() {
return m_pDocument->HasFlag(XFA_DOCFLAG_StrictScoping);
}
-XFA_ScriptDataType CFXJSE_Engine::GetType() {
+CXFA_ScriptData::Type CFXJSE_Engine::GetType() {
return m_eScriptType;
}
@@ -574,7 +574,7 @@ int32_t CFXJSE_Engine::ResolveObjects(CXFA_Object* refObject,
if (wsExpression.IsEmpty())
return 0;
- if (m_eScriptType != XFA_ScriptDataType::Formcalc ||
+ if (m_eScriptType != CXFA_ScriptData::Type::Formcalc ||
(dwStyles & (XFA_RESOLVENODE_Parent | XFA_RESOLVENODE_Siblings))) {
m_upObjectArray.clear();
}