summaryrefslogtreecommitdiff
path: root/xfa
diff options
context:
space:
mode:
authortsepez <tsepez@chromium.org>2016-06-07 13:28:15 -0700
committerCommit bot <commit-bot@chromium.org>2016-06-07 13:28:15 -0700
commit5c147bd26194fc00e6bbc63110bca092386478af (patch)
treed5dc332b0f2bc71f209ef7b7d4609e8faf5cd870 /xfa
parentbd1aa37663864b228a5053c36133399464f1079f (diff)
downloadpdfium-5c147bd26194fc00e6bbc63110bca092386478af.tar.xz
Remove casts to same type in xfa_script_imp.cpp
Review-Url: https://codereview.chromium.org/2046133002
Diffstat (limited to 'xfa')
-rw-r--r--xfa/fxfa/parser/xfa_script_imp.cpp16
1 files changed, 7 insertions, 9 deletions
diff --git a/xfa/fxfa/parser/xfa_script_imp.cpp b/xfa/fxfa/parser/xfa_script_imp.cpp
index 55034a6399..c124ac36a1 100644
--- a/xfa/fxfa/parser/xfa_script_imp.cpp
+++ b/xfa/fxfa/parser/xfa_script_imp.cpp
@@ -159,8 +159,7 @@ void CXFA_ScriptContext::GlobalPropertySetter(CFXJSE_Value* pObject,
CFXJSE_Value* pValue) {
CXFA_Object* lpOrginalNode = ToObject(pObject, nullptr);
CXFA_Document* pDoc = lpOrginalNode->GetDocument();
- CXFA_ScriptContext* lpScriptContext =
- (CXFA_ScriptContext*)pDoc->GetScriptContext();
+ CXFA_ScriptContext* lpScriptContext = pDoc->GetScriptContext();
CXFA_Object* lpCurNode = lpScriptContext->GetVariablesThis(lpOrginalNode);
CFX_WideString wsPropName = CFX_WideString::FromUTF8(szPropName);
uint32_t dwFlag = XFA_RESOLVENODE_Parent | XFA_RESOLVENODE_Siblings |
@@ -215,8 +214,7 @@ void CXFA_ScriptContext::GlobalPropertyGetter(CFXJSE_Value* pObject,
CFXJSE_Value* pValue) {
CXFA_Object* pOriginalObject = ToObject(pObject, nullptr);
CXFA_Document* pDoc = pOriginalObject->GetDocument();
- CXFA_ScriptContext* lpScriptContext =
- (CXFA_ScriptContext*)pDoc->GetScriptContext();
+ CXFA_ScriptContext* lpScriptContext = pDoc->GetScriptContext();
CXFA_Object* lpCurNode = lpScriptContext->GetVariablesThis(pOriginalObject);
CFX_WideString wsPropName = CFX_WideString::FromUTF8(szPropName);
if (lpScriptContext->GetType() == XFA_SCRIPTLANGTYPE_Formcalc) {
@@ -274,7 +272,7 @@ void CXFA_ScriptContext::NormalPropertyGetter(CFXJSE_Value* pOriginalValue,
}
CFX_WideString wsPropName = CFX_WideString::FromUTF8(szPropName);
CXFA_ScriptContext* lpScriptContext =
- (CXFA_ScriptContext*)pOriginalObject->GetDocument()->GetScriptContext();
+ pOriginalObject->GetDocument()->GetScriptContext();
CXFA_Object* pObject = lpScriptContext->GetVariablesThis(pOriginalObject);
if (wsPropName == FX_WSTRC(L"xfa")) {
CFXJSE_Value* pValue = lpScriptContext->GetJSValueFromMap(
@@ -317,7 +315,7 @@ void CXFA_ScriptContext::NormalPropertySetter(CFXJSE_Value* pOriginalValue,
return;
CXFA_ScriptContext* lpScriptContext =
- (CXFA_ScriptContext*)pOriginalObject->GetDocument()->GetScriptContext();
+ pOriginalObject->GetDocument()->GetScriptContext();
CXFA_Object* pObject = lpScriptContext->GetVariablesThis(pOriginalObject);
CFX_WideString wsPropName = CFX_WideString::FromUTF8(szPropName);
const XFA_SCRIPTATTRIBUTEINFO* lpAttributeInfo = XFA_GetScriptAttributeByName(
@@ -368,7 +366,7 @@ int32_t CXFA_ScriptContext::NormalPropTypeGetter(
return FXJSE_ClassPropType_None;
CXFA_ScriptContext* lpScriptContext =
- (CXFA_ScriptContext*)pObject->GetDocument()->GetScriptContext();
+ pObject->GetDocument()->GetScriptContext();
pObject = lpScriptContext->GetVariablesThis(pObject);
XFA_ELEMENT objElement = pObject->GetClassID();
CFX_WideString wsPropName = CFX_WideString::FromUTF8(szPropName);
@@ -390,7 +388,7 @@ int32_t CXFA_ScriptContext::GlobalPropTypeGetter(
return FXJSE_ClassPropType_None;
CXFA_ScriptContext* lpScriptContext =
- (CXFA_ScriptContext*)pObject->GetDocument()->GetScriptContext();
+ pObject->GetDocument()->GetScriptContext();
pObject = lpScriptContext->GetVariablesThis(pObject);
XFA_ELEMENT objElement = pObject->GetClassID();
CFX_WideString wsPropName = CFX_WideString::FromUTF8(szPropName);
@@ -407,7 +405,7 @@ void CXFA_ScriptContext::NormalMethodCall(CFXJSE_Value* pThis,
return;
CXFA_ScriptContext* lpScriptContext =
- (CXFA_ScriptContext*)pObject->GetDocument()->GetScriptContext();
+ pObject->GetDocument()->GetScriptContext();
pObject = lpScriptContext->GetVariablesThis(pObject);
CFX_WideString wsFunName = CFX_WideString::FromUTF8(szFuncName);
const XFA_METHODINFO* lpMethodInfo =