summaryrefslogtreecommitdiff
path: root/xfa/fxfa/parser
diff options
context:
space:
mode:
Diffstat (limited to 'xfa/fxfa/parser')
-rw-r--r--xfa/fxfa/parser/xfa_document_datamerger_imp.cpp4
-rw-r--r--xfa/fxfa/parser/xfa_document_serialize.cpp4
-rw-r--r--xfa/fxfa/parser/xfa_object_imp.cpp19
-rw-r--r--xfa/fxfa/parser/xfa_objectacc_imp.cpp2
-rw-r--r--xfa/fxfa/parser/xfa_parser_imp.cpp2
5 files changed, 15 insertions, 16 deletions
diff --git a/xfa/fxfa/parser/xfa_document_datamerger_imp.cpp b/xfa/fxfa/parser/xfa_document_datamerger_imp.cpp
index e525532f7c..5d371619e4 100644
--- a/xfa/fxfa/parser/xfa_document_datamerger_imp.cpp
+++ b/xfa/fxfa/parser/xfa_document_datamerger_imp.cpp
@@ -79,9 +79,9 @@ static FX_BOOL XFA_DataMerge_FormValueNode_SetChildContent(
CFX_WideString wsContentType;
pChildNode->GetAttribute(XFA_ATTRIBUTE_ContentType, wsContentType,
FALSE);
- if (wsContentType.Equal(FX_WSTRC(L"text/html"))) {
+ if (wsContentType == FX_WSTRC(L"text/html")) {
element = XFA_ELEMENT_SharpxHTML;
- } else if (wsContentType.Equal(FX_WSTRC(L"text/xml"))) {
+ } else if (wsContentType == FX_WSTRC(L"text/xml")) {
element = XFA_ELEMENT_Sharpxml;
}
}
diff --git a/xfa/fxfa/parser/xfa_document_serialize.cpp b/xfa/fxfa/parser/xfa_document_serialize.cpp
index f207b32263..448acbdd1d 100644
--- a/xfa/fxfa/parser/xfa_document_serialize.cpp
+++ b/xfa/fxfa/parser/xfa_document_serialize.cpp
@@ -242,7 +242,7 @@ static void XFA_DataExporter_RegenerateFormFile_Changed(
CFX_WideString wsContentType;
pNode->GetAttribute(XFA_ATTRIBUTE_ContentType, wsContentType, FALSE);
if (pRawValueNode->GetClassID() == XFA_ELEMENT_SharpxHTML &&
- wsContentType.Equal(FX_WSTRC(L"text/html"))) {
+ wsContentType == FX_WSTRC(L"text/html")) {
CFDE_XMLNode* pExDataXML = pNode->GetXMLMappingNode();
if (!pExDataXML) {
break;
@@ -264,7 +264,7 @@ static void XFA_DataExporter_RegenerateFormFile_Changed(
pTempStream->Release();
pMemStream->Release();
} else if (pRawValueNode->GetClassID() == XFA_ELEMENT_Sharpxml &&
- wsContentType.Equal(FX_WSTRC(L"text/xml"))) {
+ wsContentType == FX_WSTRC(L"text/xml")) {
CFX_WideString wsRawValue;
pRawValueNode->GetAttribute(XFA_ATTRIBUTE_Value, wsRawValue, FALSE);
if (wsRawValue.IsEmpty()) {
diff --git a/xfa/fxfa/parser/xfa_object_imp.cpp b/xfa/fxfa/parser/xfa_object_imp.cpp
index 0bd114b6c4..15f21c8a23 100644
--- a/xfa/fxfa/parser/xfa_object_imp.cpp
+++ b/xfa/fxfa/parser/xfa_object_imp.cpp
@@ -1078,7 +1078,7 @@ void CXFA_Node::Script_NodeClass_SaveXML(CFXJSE_Arguments* pArguments) {
FX_BOOL bPrettyMode = FALSE;
if (iLength == 1) {
CFX_ByteString bsPretty = pArguments->GetUTF8String(0);
- if (!bsPretty.Equal("pretty")) {
+ if (bsPretty != "pretty") {
ThrowScriptErrorMessage(XFA_IDS_ARGUMENT_MISMATCH);
return;
}
@@ -1259,7 +1259,7 @@ void CXFA_Node::Script_ModelClass_IsCompatibleNS(CFXJSE_Arguments* pArguments) {
TryNamespace(wsNodeNameSpace);
FXJSE_HVALUE hValue = pArguments->GetReturnValue();
if (hValue) {
- FXJSE_Value_SetBoolean(hValue, wsNodeNameSpace.Equal(wsNameSpace));
+ FXJSE_Value_SetBoolean(hValue, wsNodeNameSpace == wsNameSpace);
}
}
void CXFA_Node::Script_ModelClass_Context(FXJSE_HVALUE hValue,
@@ -1748,7 +1748,7 @@ void CXFA_Node::Script_Boolean_Value(FXJSE_HVALUE hValue,
SetScriptContent(wsNewValue, wsFormatValue, TRUE, TRUE);
} else {
CFX_WideString wsValue = GetScriptContent(TRUE);
- FXJSE_Value_SetBoolean(hValue, wsValue.Equal(FX_WSTRC(L"1")));
+ FXJSE_Value_SetBoolean(hValue, wsValue == FX_WSTRC(L"1"));
}
}
struct XFA_ExecEventParaInfo {
@@ -4303,17 +4303,16 @@ FX_BOOL CXFA_Node::SetScriptContent(const CFX_WideString& wsContent,
CFX_WideString wsContentType;
if (GetClassID() == XFA_ELEMENT_ExData) {
GetAttribute(XFA_ATTRIBUTE_ContentType, wsContentType, FALSE);
- if (wsContentType.Equal(FX_WSTRC(L"text/html"))) {
+ if (wsContentType == FX_WSTRC(L"text/html")) {
wsContentType = FX_WSTRC(L"");
SetAttribute(XFA_ATTRIBUTE_ContentType, wsContentType);
}
}
CXFA_Node* pContentRawDataNode = GetNodeItem(XFA_NODEITEM_FirstChild);
if (!pContentRawDataNode) {
- pContentRawDataNode =
- CreateSamePacketNode((wsContentType.Equal(FX_WSTRC(L"text/xml")))
- ? XFA_ELEMENT_Sharpxml
- : XFA_ELEMENT_Sharptext);
+ pContentRawDataNode = CreateSamePacketNode(
+ (wsContentType == FX_WSTRC(L"text/xml")) ? XFA_ELEMENT_Sharpxml
+ : XFA_ELEMENT_Sharptext);
InsertChild(pContentRawDataNode);
}
return pContentRawDataNode->SetScriptContent(
@@ -4409,9 +4408,9 @@ FX_BOOL CXFA_Node::TryContent(CFX_WideString& wsContent,
if (GetClassID() == XFA_ELEMENT_ExData) {
CFX_WideString wsContentType;
GetAttribute(XFA_ATTRIBUTE_ContentType, wsContentType, FALSE);
- if (wsContentType.Equal(FX_WSTRC(L"text/html"))) {
+ if (wsContentType == FX_WSTRC(L"text/html")) {
element = XFA_ELEMENT_SharpxHTML;
- } else if (wsContentType.Equal(FX_WSTRC(L"text/xml"))) {
+ } else if (wsContentType == FX_WSTRC(L"text/xml")) {
element = XFA_ELEMENT_Sharpxml;
}
}
diff --git a/xfa/fxfa/parser/xfa_objectacc_imp.cpp b/xfa/fxfa/parser/xfa_objectacc_imp.cpp
index b634746ef4..8c438c5634 100644
--- a/xfa/fxfa/parser/xfa_objectacc_imp.cpp
+++ b/xfa/fxfa/parser/xfa_objectacc_imp.cpp
@@ -2273,7 +2273,7 @@ IFX_Locale* CXFA_WidgetData::GetLocal() {
CFX_WideString wsLocaleName;
bLocale = m_pNode->GetLocaleName(wsLocaleName);
if (bLocale) {
- if (wsLocaleName.Equal(FX_WSTRC(L"ambient"))) {
+ if (wsLocaleName == FX_WSTRC(L"ambient")) {
pLocale = m_pNode->GetDocument()->GetLocalMgr()->GetDefLocale();
} else {
pLocale =
diff --git a/xfa/fxfa/parser/xfa_parser_imp.cpp b/xfa/fxfa/parser/xfa_parser_imp.cpp
index a2c2ae7909..71c37755f9 100644
--- a/xfa/fxfa/parser/xfa_parser_imp.cpp
+++ b/xfa/fxfa/parser/xfa_parser_imp.cpp
@@ -1456,7 +1456,7 @@ int32_t CXFA_XMLParser::DoParser(IFX_Pause* pPause) {
}
m_pParser->GetTagName(m_ws1);
static_cast<CFDE_XMLElement*>(m_pChild)->GetTagName(m_ws2);
- if (m_ws1.GetLength() > 0 && !m_ws1.Equal(m_ws2)) {
+ if (m_ws1.GetLength() > 0 && m_ws1 != m_ws2) {
m_dwStatus = FDE_XMLSYNTAXSTATUS_Error;
break;
}