summaryrefslogtreecommitdiff
path: root/fxjs
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2017-11-02 19:15:03 +0000
committerChromium commit bot <commit-bot@chromium.org>2017-11-02 19:15:03 +0000
commit8946aec4c3e727aae806f9858c2329ce368dd517 (patch)
tree6d01927599e7c069e957b5ce9f57456f56aacdcb /fxjs
parent23aa2b0f8a3202337a40e8dcf3d8340bfd42e004 (diff)
downloadpdfium-8946aec4c3e727aae806f9858c2329ce368dd517.tar.xz
Remove default values from CJX_Node::TryContent
This CL removes the default values from TryContent and inlines into the call sites. Change-Id: I2d3f41f77364a0b923931479a60e07eae98dd5a9 Reviewed-on: https://pdfium-review.googlesource.com/17550 Commit-Queue: dsinclair <dsinclair@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org>
Diffstat (limited to 'fxjs')
-rw-r--r--fxjs/cjx_node.cpp4
-rw-r--r--fxjs/cjx_node.h4
2 files changed, 3 insertions, 5 deletions
diff --git a/fxjs/cjx_node.cpp b/fxjs/cjx_node.cpp
index 1724881c55..b4f480e537 100644
--- a/fxjs/cjx_node.cpp
+++ b/fxjs/cjx_node.cpp
@@ -959,7 +959,7 @@ void CJX_Node::Script_NodeClass_IsNull(CFXJSE_Value* pValue,
return;
}
WideString strValue;
- pValue->SetBoolean(!TryContent(strValue) || strValue.IsEmpty());
+ pValue->SetBoolean(!TryContent(strValue, false, true) || strValue.IsEmpty());
}
void CJX_Node::Script_NodeClass_OneOfChild(CFXJSE_Value* pValue,
@@ -3508,7 +3508,7 @@ bool CJX_Node::SetContent(const WideString& wsContent,
WideString CJX_Node::GetScriptContent(bool bScriptModify) {
WideString wsContent;
- return TryContent(wsContent, bScriptModify) ? wsContent : WideString();
+ return TryContent(wsContent, bScriptModify, true) ? wsContent : WideString();
}
WideString CJX_Node::GetContent() {
diff --git a/fxjs/cjx_node.h b/fxjs/cjx_node.h
index 7df789df50..7256e31c19 100644
--- a/fxjs/cjx_node.h
+++ b/fxjs/cjx_node.h
@@ -92,9 +92,7 @@ class CJX_Node : public CJX_Object {
bool bScriptModify);
WideStringView GetCData(XFA_ATTRIBUTE eAttr);
- bool TryContent(WideString& wsContent,
- bool bScriptModify = false,
- bool bProto = true);
+ bool TryContent(WideString& wsContent, bool bScriptModify, bool bProto);
bool TryEnum(XFA_ATTRIBUTE eAttr,
XFA_ATTRIBUTEENUM& eValue,