summaryrefslogtreecommitdiff
path: root/xfa/src/fxfa
diff options
context:
space:
mode:
Diffstat (limited to 'xfa/src/fxfa')
-rw-r--r--xfa/src/fxfa/src/app/xfa_checksum.cpp12
-rw-r--r--xfa/src/fxfa/src/app/xfa_checksum.h12
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffbarcode.cpp4
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffchoicelist.cpp4
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffchoicelist.h4
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffdoc.cpp6
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffdoc.h6
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffdochandler.cpp6
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffdochandler.h6
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffdocview.cpp8
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffdocview.h8
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffnotify.cpp4
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffpageview.cpp2
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffpageview.h2
-rw-r--r--xfa/src/fxfa/src/app/xfa_fftextedit.cpp6
-rw-r--r--xfa/src/fxfa/src/app/xfa_fftextedit.h6
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffwidget.cpp2
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffwidget.h4
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffwidgetacc.cpp2
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffwidgethandler.cpp2
-rw-r--r--xfa/src/fxfa/src/app/xfa_ffwidgethandler.h2
-rw-r--r--xfa/src/fxfa/src/app/xfa_fontmgr.cpp14
-rw-r--r--xfa/src/fxfa/src/app/xfa_fontmgr.h10
-rw-r--r--xfa/src/fxfa/src/app/xfa_fwladapter.h4
-rw-r--r--xfa/src/fxfa/src/common/xfa_document.h4
-rw-r--r--xfa/src/fxfa/src/common/xfa_fm2jsapi.h2
-rw-r--r--xfa/src/fxfa/src/common/xfa_localemgr.h2
-rw-r--r--xfa/src/fxfa/src/common/xfa_object.h18
-rw-r--r--xfa/src/fxfa/src/common/xfa_script.h4
-rw-r--r--xfa/src/fxfa/src/common/xfa_utils.h4
-rw-r--r--xfa/src/fxfa/src/fm2js/xfa_expression.cpp8
-rw-r--r--xfa/src/fxfa/src/fm2js/xfa_expression.h8
-rw-r--r--xfa/src/fxfa/src/fm2js/xfa_fm2jsapi.cpp2
-rw-r--r--xfa/src/fxfa/src/fm2js/xfa_fm2jscontext.cpp232
-rw-r--r--xfa/src/fxfa/src/fm2js/xfa_fm2jscontext.h230
-rw-r--r--xfa/src/fxfa/src/fm2js/xfa_fmparse.cpp2
-rw-r--r--xfa/src/fxfa/src/fm2js/xfa_fmparse.h2
-rw-r--r--xfa/src/fxfa/src/fm2js/xfa_lexer.cpp4
-rw-r--r--xfa/src/fxfa/src/fm2js/xfa_lexer.h4
-rw-r--r--xfa/src/fxfa/src/fm2js/xfa_program.cpp2
-rw-r--r--xfa/src/fxfa/src/fm2js/xfa_program.h2
-rw-r--r--xfa/src/fxfa/src/fm2js/xfa_simpleexpression.cpp2
-rw-r--r--xfa/src/fxfa/src/fm2js/xfa_simpleexpression.h2
-rw-r--r--xfa/src/fxfa/src/parser/xfa_basic_imp.cpp16
-rw-r--r--xfa/src/fxfa/src/parser/xfa_document_datadescription_imp.cpp2
-rw-r--r--xfa/src/fxfa/src/parser/xfa_document_datadescription_imp.h2
-rw-r--r--xfa/src/fxfa/src/parser/xfa_document_imp.cpp4
-rw-r--r--xfa/src/fxfa/src/parser/xfa_document_serialize.cpp4
-rw-r--r--xfa/src/fxfa/src/parser/xfa_locale.cpp8
-rw-r--r--xfa/src/fxfa/src/parser/xfa_locale.h8
-rw-r--r--xfa/src/fxfa/src/parser/xfa_localemgr.cpp2
-rw-r--r--xfa/src/fxfa/src/parser/xfa_object_imp.cpp22
-rw-r--r--xfa/src/fxfa/src/parser/xfa_objectacc_imp.cpp20
-rw-r--r--xfa/src/fxfa/src/parser/xfa_parser_imp.cpp10
-rw-r--r--xfa/src/fxfa/src/parser/xfa_script_hostpseudomodel.cpp2
-rw-r--r--xfa/src/fxfa/src/parser/xfa_script_imp.cpp24
-rw-r--r--xfa/src/fxfa/src/parser/xfa_script_imp.h24
-rw-r--r--xfa/src/fxfa/src/parser/xfa_script_resolveprocessor.cpp4
-rw-r--r--xfa/src/fxfa/src/parser/xfa_script_resolveprocessor.h4
-rw-r--r--xfa/src/fxfa/src/parser/xfa_utils_imp.cpp2
60 files changed, 414 insertions, 414 deletions
diff --git a/xfa/src/fxfa/src/app/xfa_checksum.cpp b/xfa/src/fxfa/src/app/xfa_checksum.cpp
index 0bb63ce79a..20546df0c6 100644
--- a/xfa/src/fxfa/src/app/xfa_checksum.cpp
+++ b/xfa/src/fxfa/src/app/xfa_checksum.cpp
@@ -15,7 +15,7 @@ CXFA_SAXReaderHandler::CXFA_SAXReaderHandler(CXFA_ChecksumContext *pContext)
CXFA_SAXReaderHandler::~CXFA_SAXReaderHandler()
{
}
-void* CXFA_SAXReaderHandler::OnTagEnter(FX_BSTR bsTagName, FX_SAXNODE eType, FX_DWORD dwStartPos)
+void* CXFA_SAXReaderHandler::OnTagEnter(const CFX_ByteStringC& bsTagName, FX_SAXNODE eType, FX_DWORD dwStartPos)
{
UpdateChecksum(TRUE);
if (eType != FX_SAXNODE_Tag && eType != FX_SAXNODE_Instruction) {
@@ -31,7 +31,7 @@ void* CXFA_SAXReaderHandler::OnTagEnter(FX_BSTR bsTagName, FX_SAXNODE eType, FX_
m_SAXContext.m_bsTagName = bsTagName;
return &m_SAXContext;
}
-void CXFA_SAXReaderHandler::OnTagAttribute(void* pTag, FX_BSTR bsAttri, FX_BSTR bsValue)
+void CXFA_SAXReaderHandler::OnTagAttribute(void* pTag, const CFX_ByteStringC& bsAttri, const CFX_ByteStringC& bsValue)
{
if (pTag == NULL) {
return;
@@ -52,7 +52,7 @@ void CXFA_SAXReaderHandler::OnTagBreak(void* pTag)
textBuf << FX_BSTRC(">");
UpdateChecksum(FALSE);
}
-void CXFA_SAXReaderHandler::OnTagData(void* pTag, FX_SAXNODE eType, FX_BSTR bsData, FX_DWORD dwStartPos)
+void CXFA_SAXReaderHandler::OnTagData(void* pTag, FX_SAXNODE eType, const CFX_ByteStringC& bsData, FX_DWORD dwStartPos)
{
if (pTag == NULL) {
return;
@@ -82,7 +82,7 @@ void CXFA_SAXReaderHandler::OnTagClose(void* pTag, FX_DWORD dwEndPos)
}
UpdateChecksum(FALSE);
}
-void CXFA_SAXReaderHandler::OnTagEnd(void* pTag, FX_BSTR bsTagName, FX_DWORD dwEndPos)
+void CXFA_SAXReaderHandler::OnTagEnd(void* pTag, const CFX_ByteStringC& bsTagName, FX_DWORD dwEndPos)
{
if (pTag == NULL) {
return;
@@ -93,7 +93,7 @@ void CXFA_SAXReaderHandler::OnTagEnd(void* pTag, FX_BSTR bsTagName, FX_DWORD dwE
textBuf << FX_BSTRC(">");
UpdateChecksum(FALSE);
}
-void CXFA_SAXReaderHandler::OnTargetData(void* pTag, FX_SAXNODE eType, FX_BSTR bsData, FX_DWORD dwStartPos)
+void CXFA_SAXReaderHandler::OnTargetData(void* pTag, FX_SAXNODE eType, const CFX_ByteStringC& bsData, FX_DWORD dwStartPos)
{
if (pTag == NULL && eType != FX_SAXNODE_Comment) {
return;
@@ -195,7 +195,7 @@ void CXFA_ChecksumContext::GetChecksum(CFX_ByteString &bsChecksum)
{
bsChecksum = m_bsChecksum;
}
-void CXFA_ChecksumContext::Update(FX_BSTR bsText)
+void CXFA_ChecksumContext::Update(const CFX_ByteStringC& bsText)
{
if (m_pByteContext != NULL) {
CRYPT_SHA1Update(m_pByteContext, bsText.GetPtr(), bsText.GetLength());
diff --git a/xfa/src/fxfa/src/app/xfa_checksum.h b/xfa/src/fxfa/src/app/xfa_checksum.h
index 8b6ecb56a6..4ffe670979 100644
--- a/xfa/src/fxfa/src/app/xfa_checksum.h
+++ b/xfa/src/fxfa/src/app/xfa_checksum.h
@@ -23,14 +23,14 @@ class CXFA_SAXReaderHandler : public IFX_SAXReaderHandler
public:
CXFA_SAXReaderHandler(CXFA_ChecksumContext *pContext);
virtual ~CXFA_SAXReaderHandler();
- virtual void* OnTagEnter(FX_BSTR bsTagName, FX_SAXNODE eType, FX_DWORD dwStartPos);
- virtual void OnTagAttribute(void* pTag, FX_BSTR bsAttri, FX_BSTR bsValue);
+ virtual void* OnTagEnter(const CFX_ByteStringC& bsTagName, FX_SAXNODE eType, FX_DWORD dwStartPos);
+ virtual void OnTagAttribute(void* pTag, const CFX_ByteStringC& bsAttri, const CFX_ByteStringC& bsValue);
virtual void OnTagBreak(void* pTag);
- virtual void OnTagData(void* pTag, FX_SAXNODE eType, FX_BSTR bsData, FX_DWORD dwStartPos);
+ virtual void OnTagData(void* pTag, FX_SAXNODE eType, const CFX_ByteStringC& bsData, FX_DWORD dwStartPos);
virtual void OnTagClose(void* pTag, FX_DWORD dwEndPos);
- virtual void OnTagEnd(void* pTag, FX_BSTR bsTagName, FX_DWORD dwEndPos);
+ virtual void OnTagEnd(void* pTag, const CFX_ByteStringC& bsTagName, FX_DWORD dwEndPos);
- virtual void OnTargetData(void* pTag, FX_SAXNODE eType, FX_BSTR bsData, FX_DWORD dwStartPos);
+ virtual void OnTargetData(void* pTag, FX_SAXNODE eType, const CFX_ByteStringC& bsData, FX_DWORD dwStartPos);
protected:
void UpdateChecksum(FX_BOOL bCheckSpace);
CXFA_ChecksumContext *m_pContext;
@@ -49,7 +49,7 @@ public:
virtual FX_BOOL UpdateChecksum(IFX_FileRead *pSrcFile, FX_FILESIZE offset = 0, size_t size = 0);
virtual void FinishChecksum();
virtual void GetChecksum(CFX_ByteString &bsChecksum);
- void Update(FX_BSTR bsText);
+ void Update(const CFX_ByteStringC& bsText);
protected:
IFX_SAXReader *m_pSAXReader;
uint8_t* m_pByteContext;
diff --git a/xfa/src/fxfa/src/app/xfa_ffbarcode.cpp b/xfa/src/fxfa/src/app/xfa_ffbarcode.cpp
index 39f11b5a32..3b04a270a2 100644
--- a/xfa/src/fxfa/src/app/xfa_ffbarcode.cpp
+++ b/xfa/src/fxfa/src/app/xfa_ffbarcode.cpp
@@ -12,7 +12,7 @@
#include "xfa_ffpageview.h"
#include "xfa_fftextedit.h"
#include "xfa_ffbarcode.h"
-static XFA_LPCBARCODETYPEENUMINFO XFA_GetBarcodeTypeByName(FX_WSTR wsName);
+static XFA_LPCBARCODETYPEENUMINFO XFA_GetBarcodeTypeByName(const CFX_WideStringC& wsName);
CXFA_FFBarcode::CXFA_FFBarcode(CXFA_FFPageView* pPageView, CXFA_WidgetAcc* pDataAcc)
: CXFA_FFTextEdit(pPageView, pDataAcc)
{
@@ -200,7 +200,7 @@ extern const XFA_BARCODETYPEENUMINFO g_XFABarCodeTypeEnumData[] = {
{0xfb48155c, L"code3Of9", XFA_BARCODETYPE_code3Of9, BC_CODE39},
};
extern const int32_t g_iXFABarcodeTypeCount = sizeof(g_XFABarCodeTypeEnumData) / sizeof(XFA_BARCODETYPEENUMINFO);
-static XFA_LPCBARCODETYPEENUMINFO XFA_GetBarcodeTypeByName(FX_WSTR wsName)
+static XFA_LPCBARCODETYPEENUMINFO XFA_GetBarcodeTypeByName(const CFX_WideStringC& wsName)
{
int32_t iLength = wsName.GetLength();
if (iLength == 0) {
diff --git a/xfa/src/fxfa/src/app/xfa_ffchoicelist.cpp b/xfa/src/fxfa/src/app/xfa_ffchoicelist.cpp
index 47685a28a7..56215aff97 100644
--- a/xfa/src/fxfa/src/app/xfa_ffchoicelist.cpp
+++ b/xfa/src/fxfa/src/app/xfa_ffchoicelist.cpp
@@ -168,7 +168,7 @@ void CXFA_FFListBox::SetItemState(int32_t nIndex, FX_BOOL bSelected)
m_pNormalWidget->Update();
AddInvalidateRect();
}
-void CXFA_FFListBox::InsertItem(FX_WSTR wsLabel, int32_t nIndex )
+void CXFA_FFListBox::InsertItem(const CFX_WideStringC& wsLabel, int32_t nIndex )
{
CFX_WideString wsTemp(wsLabel);
((CFWL_ListBox*)m_pNormalWidget)->AddString(wsTemp);
@@ -483,7 +483,7 @@ void CXFA_FFComboBox::SetItemState(int32_t nIndex, FX_BOOL bSelected)
m_pNormalWidget->Update();
AddInvalidateRect();
}
-void CXFA_FFComboBox::InsertItem(FX_WSTR wsLabel, int32_t nIndex )
+void CXFA_FFComboBox::InsertItem(const CFX_WideStringC& wsLabel, int32_t nIndex )
{
((CFWL_ComboBox*)m_pNormalWidget)->AddString(wsLabel);
m_pNormalWidget->Update();
diff --git a/xfa/src/fxfa/src/app/xfa_ffchoicelist.h b/xfa/src/fxfa/src/app/xfa_ffchoicelist.h
index c6ed12b668..aeddedbcc9 100644
--- a/xfa/src/fxfa/src/app/xfa_ffchoicelist.h
+++ b/xfa/src/fxfa/src/app/xfa_ffchoicelist.h
@@ -21,7 +21,7 @@ protected:
public:
void OnSelectChanged(IFWL_Widget *pWidget, const CFX_Int32Array &arrSels);
void SetItemState(int32_t nIndex, FX_BOOL bSelected);
- void InsertItem(FX_WSTR wsLabel, int32_t nIndex = -1);
+ void InsertItem(const CFX_WideStringC& wsLabel, int32_t nIndex = -1);
void DeleteItem(int32_t nIndex);
virtual int32_t OnProcessMessage(CFWL_Message *pMessage);
virtual FWL_ERR OnProcessEvent(CFWL_Event *pEvent);
@@ -71,7 +71,7 @@ public:
void OnPostOpen(IFWL_Widget *pWidget);
void OnAddDoRecord(IFWL_Widget *pWidget);
void SetItemState(int32_t nIndex, FX_BOOL bSelected);
- void InsertItem(FX_WSTR wsLabel, int32_t nIndex = -1);
+ void InsertItem(const CFX_WideStringC& wsLabel, int32_t nIndex = -1);
void DeleteItem(int32_t nIndex);
virtual int32_t OnProcessMessage(CFWL_Message *pMessage);
virtual FWL_ERR OnProcessEvent(CFWL_Event *pEvent);
diff --git a/xfa/src/fxfa/src/app/xfa_ffdoc.cpp b/xfa/src/fxfa/src/app/xfa_ffdoc.cpp
index 97514c83ae..36e69dbb65 100644
--- a/xfa/src/fxfa/src/app/xfa_ffdoc.cpp
+++ b/xfa/src/fxfa/src/app/xfa_ffdoc.cpp
@@ -327,7 +327,7 @@ CPDF_Document* CXFA_FFDoc::GetPDFDoc()
return m_pPDFDoc;
}
#define _FXLIB_NEW_VERSION_
-CFX_DIBitmap* CXFA_FFDoc::GetPDFNamedImage(FX_WSTR wsName, int32_t &iImageXDpi, int32_t &iImageYDpi)
+CFX_DIBitmap* CXFA_FFDoc::GetPDFNamedImage(const CFX_WideStringC& wsName, int32_t &iImageXDpi, int32_t &iImageYDpi)
{
if (!m_pPDFDoc) {
return NULL;
@@ -399,7 +399,7 @@ CFX_DIBitmap* CXFA_FFDoc::GetPDFNamedImage(FX_WSTR wsName, int32_t &iImageXDpi,
m_mapNamedImages.SetAt((void*)(uintptr_t)dwHash, imageDIBDpi);
return (CFX_DIBitmap*)imageDIBDpi->pDibSource;
}
-IFDE_XMLElement* CXFA_FFDoc::GetPackageData(FX_WSTR wsPackage)
+IFDE_XMLElement* CXFA_FFDoc::GetPackageData(const CFX_WideStringC& wsPackage)
{
FX_DWORD packetHash = FX_HashCode_String_GetW(wsPackage.GetPtr(), wsPackage.GetLength());
CXFA_Object* pObject = m_pDocument->GetXFANode(packetHash);
@@ -410,7 +410,7 @@ IFDE_XMLElement* CXFA_FFDoc::GetPackageData(FX_WSTR wsPackage)
IFDE_XMLNode *pXMLNode = pNode->GetXMLMappingNode();
return (pXMLNode && pXMLNode->GetType() == FDE_XMLNODE_Element) ? (IFDE_XMLElement *)pXMLNode : NULL;
}
-FX_BOOL CXFA_FFDoc::SavePackage(FX_WSTR wsPackage, IFX_FileWrite* pFile, IXFA_ChecksumContext *pCSContext )
+FX_BOOL CXFA_FFDoc::SavePackage(const CFX_WideStringC& wsPackage, IFX_FileWrite* pFile, IXFA_ChecksumContext *pCSContext )
{
IXFA_PacketExport *pExport = IXFA_PacketExport::Create(m_pDocument);
if (!pExport) {
diff --git a/xfa/src/fxfa/src/app/xfa_ffdoc.h b/xfa/src/fxfa/src/app/xfa_ffdoc.h
index a8c5b80370..caea408112 100644
--- a/xfa/src/fxfa/src/app/xfa_ffdoc.h
+++ b/xfa/src/fxfa/src/app/xfa_ffdoc.h
@@ -49,9 +49,9 @@ public:
CXFA_FFDocView* GetDocView(IXFA_DocLayout* pLayout);
CXFA_FFDocView* GetDocView();
CPDF_Document* GetPDFDoc();
- CFX_DIBitmap* GetPDFNamedImage(FX_WSTR wsName, int32_t &iImageXDpi, int32_t &iImageYDpi);
- IFDE_XMLElement* GetPackageData(FX_WSTR wsPackage);
- FX_BOOL SavePackage(FX_WSTR wsPackage, IFX_FileWrite* pFile, IXFA_ChecksumContext *pCSContext = NULL);
+ CFX_DIBitmap* GetPDFNamedImage(const CFX_WideStringC& wsName, int32_t &iImageXDpi, int32_t &iImageYDpi);
+ IFDE_XMLElement* GetPackageData(const CFX_WideStringC& wsPackage);
+ FX_BOOL SavePackage(const CFX_WideStringC& wsPackage, IFX_FileWrite* pFile, IXFA_ChecksumContext *pCSContext = NULL);
FX_BOOL ImportData(IFX_FileRead* pStream, FX_BOOL bXDP = TRUE);
protected:
IXFA_DocProvider* m_pDocProvider;
diff --git a/xfa/src/fxfa/src/app/xfa_ffdochandler.cpp b/xfa/src/fxfa/src/app/xfa_ffdochandler.cpp
index ccc734ecad..79375c21d9 100644
--- a/xfa/src/fxfa/src/app/xfa_ffdochandler.cpp
+++ b/xfa/src/fxfa/src/app/xfa_ffdochandler.cpp
@@ -50,11 +50,11 @@ int32_t CXFA_FFDocHandler::CountPackages(IXFA_Doc* hDoc)
void CXFA_FFDocHandler::GetPackageName(IXFA_Doc* hDoc, int32_t iPackage, CFX_WideStringC &wsPackage)
{
}
-IFDE_XMLElement* CXFA_FFDocHandler::GetPackageData(IXFA_Doc* hDoc, FX_WSTR wsPackage)
+IFDE_XMLElement* CXFA_FFDocHandler::GetPackageData(IXFA_Doc* hDoc, const CFX_WideStringC& wsPackage)
{
return static_cast<CXFA_FFDoc*>(hDoc)->GetPackageData(wsPackage);
}
-FX_BOOL CXFA_FFDocHandler::SavePackage(IXFA_Doc* hDoc, FX_WSTR wsPackage, IFX_FileWrite* pFile, IXFA_ChecksumContext *pCSContext )
+FX_BOOL CXFA_FFDocHandler::SavePackage(IXFA_Doc* hDoc, const CFX_WideStringC& wsPackage, IFX_FileWrite* pFile, IXFA_ChecksumContext *pCSContext )
{
return static_cast<CXFA_FFDoc*>(hDoc)->SavePackage(wsPackage, pFile, pCSContext);
}
@@ -99,7 +99,7 @@ XFA_ATTRIBUTEENUM CXFA_FFDocHandler::GetRestoreState(IXFA_Doc* hDoc)
}
return pSubForm->GetEnum(XFA_ATTRIBUTE_RestoreState);
}
-FX_BOOL CXFA_FFDocHandler::RunDocScript(IXFA_Doc* hDoc, XFA_SCRIPTTYPE eScriptType, FX_WSTR wsScript, FXJSE_HVALUE hRetValue, FXJSE_HVALUE hThisObject)
+FX_BOOL CXFA_FFDocHandler::RunDocScript(IXFA_Doc* hDoc, XFA_SCRIPTTYPE eScriptType, const CFX_WideStringC& wsScript, FXJSE_HVALUE hRetValue, FXJSE_HVALUE hThisObject)
{
CXFA_Document* pXFADoc = static_cast<CXFA_FFDoc*>(hDoc)->GetXFADoc();
if (!pXFADoc) {
diff --git a/xfa/src/fxfa/src/app/xfa_ffdochandler.h b/xfa/src/fxfa/src/app/xfa_ffdochandler.h
index a421610d29..b087709bc2 100644
--- a/xfa/src/fxfa/src/app/xfa_ffdochandler.h
+++ b/xfa/src/fxfa/src/app/xfa_ffdochandler.h
@@ -22,14 +22,14 @@ public:
virtual IXFA_DocView* CreateDocView(IXFA_Doc* hDoc, FX_DWORD dwView = 0);
virtual int32_t CountPackages(IXFA_Doc* hDoc);
virtual void GetPackageName(IXFA_Doc* hDoc, int32_t iPackage, CFX_WideStringC &wsPackage);
- virtual IFDE_XMLElement* GetPackageData(IXFA_Doc* hDoc, FX_WSTR wsPackage);
- virtual FX_BOOL SavePackage(IXFA_Doc* hDoc, FX_WSTR wsPackage, IFX_FileWrite* pFile, IXFA_ChecksumContext *pCSContext = NULL);
+ virtual IFDE_XMLElement* GetPackageData(IXFA_Doc* hDoc, const CFX_WideStringC& wsPackage);
+ virtual FX_BOOL SavePackage(IXFA_Doc* hDoc, const CFX_WideStringC& wsPackage, IFX_FileWrite* pFile, IXFA_ChecksumContext *pCSContext = NULL);
virtual FX_BOOL CloseDoc(IXFA_Doc* hDoc);
virtual FX_BOOL ImportData(IXFA_Doc* hDoc, IFX_FileRead* pStream, FX_BOOL bXDP = TRUE);
virtual void SetJSERuntime(IXFA_Doc* hDoc, FXJSE_HRUNTIME hRuntime);
virtual FXJSE_HVALUE GetXFAScriptObject(IXFA_Doc* hDoc);
virtual XFA_ATTRIBUTEENUM GetRestoreState(IXFA_Doc* hDoc);
- virtual FX_BOOL RunDocScript(IXFA_Doc* hDoc, XFA_SCRIPTTYPE eScriptType, FX_WSTR wsScript, FXJSE_HVALUE hRetValue, FXJSE_HVALUE hThisObject);
+ virtual FX_BOOL RunDocScript(IXFA_Doc* hDoc, XFA_SCRIPTTYPE eScriptType, const CFX_WideStringC& wsScript, FXJSE_HVALUE hRetValue, FXJSE_HVALUE hThisObject);
protected:
};
diff --git a/xfa/src/fxfa/src/app/xfa_ffdocview.cpp b/xfa/src/fxfa/src/app/xfa_ffdocview.cpp
index 1532e28607..e67612dbf4 100644
--- a/xfa/src/fxfa/src/app/xfa_ffdocview.cpp
+++ b/xfa/src/fxfa/src/app/xfa_ffdocview.cpp
@@ -222,11 +222,11 @@ IXFA_PageView* CXFA_FFDocView::GetPageView(int32_t nIndex)
}
return (CXFA_FFPageView*)m_pXFADocLayout->GetPage(nIndex);
}
-IXFA_Widget* CXFA_FFDocView::GetWidgetByName(FX_WSTR wsName)
+IXFA_Widget* CXFA_FFDocView::GetWidgetByName(const CFX_WideStringC& wsName)
{
return GetWidgetByName(wsName, NULL);
}
-CXFA_WidgetAcc* CXFA_FFDocView::GetWidgetAccByName(FX_WSTR wsName)
+CXFA_WidgetAcc* CXFA_FFDocView::GetWidgetAccByName(const CFX_WideStringC& wsName)
{
return GetWidgetAccByName(wsName, NULL);
}
@@ -504,7 +504,7 @@ int32_t CXFA_FFDocView::ExecEventActivityByDeepFirst(CXFA_Node* pFormNode, XFA_E
iRet |= XFA_ProcessEvent(this, pWidgetAcc, &eParam);
return iRet;
}
-CXFA_FFWidget* CXFA_FFDocView::GetWidgetByName(FX_WSTR wsName, CXFA_FFWidget* pRefWidget )
+CXFA_FFWidget* CXFA_FFDocView::GetWidgetByName(const CFX_WideStringC& wsName, CXFA_FFWidget* pRefWidget )
{
CXFA_WidgetAcc* pRefAcc = pRefWidget ? pRefWidget->GetDataAcc() : NULL;
if (CXFA_WidgetAcc* pAcc = GetWidgetAccByName(wsName, pRefAcc)) {
@@ -512,7 +512,7 @@ CXFA_FFWidget* CXFA_FFDocView::GetWidgetByName(FX_WSTR wsName, CXFA_FFWidget* pR
}
return NULL;
}
-CXFA_WidgetAcc* CXFA_FFDocView::GetWidgetAccByName(FX_WSTR wsName, CXFA_WidgetAcc* pRefWidgetAcc )
+CXFA_WidgetAcc* CXFA_FFDocView::GetWidgetAccByName(const CFX_WideStringC& wsName, CXFA_WidgetAcc* pRefWidgetAcc )
{
CFX_WideString wsExpression;
FX_DWORD dwStyle = XFA_RESOLVENODE_Children | XFA_RESOLVENODE_Properties | XFA_RESOLVENODE_Siblings | XFA_RESOLVENODE_Parent;
diff --git a/xfa/src/fxfa/src/app/xfa_ffdocview.h b/xfa/src/fxfa/src/app/xfa_ffdocview.h
index e7493e653d..557a39f3f6 100644
--- a/xfa/src/fxfa/src/app/xfa_ffdocview.h
+++ b/xfa/src/fxfa/src/app/xfa_ffdocview.h
@@ -45,8 +45,8 @@ public:
virtual void UpdateDocView();
virtual int32_t CountPageViews();
virtual IXFA_PageView* GetPageView(int32_t nIndex);
- virtual IXFA_Widget* GetWidgetByName(FX_WSTR wsName);
- virtual CXFA_WidgetAcc* GetWidgetAccByName(FX_WSTR wsName);
+ virtual IXFA_Widget* GetWidgetByName(const CFX_WideStringC& wsName);
+ virtual CXFA_WidgetAcc* GetWidgetAccByName(const CFX_WideStringC& wsName);
virtual void ResetWidgetData(CXFA_WidgetAcc* pWidgetAcc = NULL);
virtual int32_t ProcessWidgetEvent(CXFA_EventParam* pParam, CXFA_WidgetAcc* pWidgetAcc = NULL);
virtual IXFA_WidgetHandler* GetWidgetHandler();
@@ -55,8 +55,8 @@ public:
virtual IXFA_Widget* GetFocusWidget();
virtual void KillFocus();
virtual FX_BOOL SetFocus(IXFA_Widget* hWidget);
- CXFA_FFWidget* GetWidgetByName(FX_WSTR wsName, CXFA_FFWidget* pRefWidget = NULL);
- CXFA_WidgetAcc* GetWidgetAccByName(FX_WSTR wsName, CXFA_WidgetAcc* pRefWidgetAcc = NULL);
+ CXFA_FFWidget* GetWidgetByName(const CFX_WideStringC& wsName, CXFA_FFWidget* pRefWidget = NULL);
+ CXFA_WidgetAcc* GetWidgetAccByName(const CFX_WideStringC& wsName, CXFA_WidgetAcc* pRefWidgetAcc = NULL);
IXFA_DocLayout* GetXFALayout() const;
void OnPageEvent(IXFA_LayoutPage *pSender, XFA_PAGEEVENT eEvent, int32_t iPageIndex);
void LockUpdate();
diff --git a/xfa/src/fxfa/src/app/xfa_ffnotify.cpp b/xfa/src/fxfa/src/app/xfa_ffnotify.cpp
index 3f96278e24..ebaf4b2674 100644
--- a/xfa/src/fxfa/src/app/xfa_ffnotify.cpp
+++ b/xfa/src/fxfa/src/app/xfa_ffnotify.cpp
@@ -91,9 +91,9 @@ void CXFA_FFNotify::OnWidgetDataEvent(CXFA_WidgetData* pSender, FX_DWORD dwEvent
while (pWidget) {
if (pWidget->IsLoaded()) {
if (pWidgetAcc->IsListBox()) {
- ((CXFA_FFListBox*)pWidget)->InsertItem((FX_WSTR)(const FX_WCHAR*)pParam, (int32_t)(uintptr_t)pAdditional2);
+ ((CXFA_FFListBox*)pWidget)->InsertItem((const CFX_WideStringC&)(const FX_WCHAR*)pParam, (int32_t)(uintptr_t)pAdditional2);
} else {
- ((CXFA_FFComboBox*)pWidget)->InsertItem((FX_WSTR)(const FX_WCHAR*)pParam, (int32_t)(uintptr_t)pAdditional2);
+ ((CXFA_FFComboBox*)pWidget)->InsertItem((const CFX_WideStringC&)(const FX_WCHAR*)pParam, (int32_t)(uintptr_t)pAdditional2);
}
}
if (bStaticNotify) {
diff --git a/xfa/src/fxfa/src/app/xfa_ffpageview.cpp b/xfa/src/fxfa/src/app/xfa_ffpageview.cpp
index ccc5d07d1a..97c5b71089 100644
--- a/xfa/src/fxfa/src/app/xfa_ffpageview.cpp
+++ b/xfa/src/fxfa/src/app/xfa_ffpageview.cpp
@@ -290,7 +290,7 @@ CXFA_FFWidget* CXFA_FFTabOrderPageWidgetIterator::GetTraverseWidget(CXFA_FFWidge
}
return NULL;
}
-CXFA_FFWidget* CXFA_FFTabOrderPageWidgetIterator::FindWidgetByName(FX_WSTR wsWidgetName, CXFA_FFWidget* pRefWidget)
+CXFA_FFWidget* CXFA_FFTabOrderPageWidgetIterator::FindWidgetByName(const CFX_WideStringC& wsWidgetName, CXFA_FFWidget* pRefWidget)
{
return pRefWidget->GetDocView()->GetWidgetByName(wsWidgetName, pRefWidget);
}
diff --git a/xfa/src/fxfa/src/app/xfa_ffpageview.h b/xfa/src/fxfa/src/app/xfa_ffpageview.h
index b80248bf0a..d417451331 100644
--- a/xfa/src/fxfa/src/app/xfa_ffpageview.h
+++ b/xfa/src/fxfa/src/app/xfa_ffpageview.h
@@ -90,7 +90,7 @@ protected:
int32_t m_iCurWidget;
FX_BOOL m_bIgnorerelevant;
CXFA_FFWidget* GetTraverseWidget(CXFA_FFWidget* pWidget);
- CXFA_FFWidget* FindWidgetByName(FX_WSTR wsWidgetName, CXFA_FFWidget* pRefWidget);
+ CXFA_FFWidget* FindWidgetByName(const CFX_WideStringC& wsWidgetName, CXFA_FFWidget* pRefWidget);
void CreateTabOrderWidgetArray();
void CreateSpaceOrderWidgetArray(CXFA_WidgetArray& WidgetArray);
CXFA_FFWidget* GetWidget(CXFA_LayoutItem* pLayoutItem);
diff --git a/xfa/src/fxfa/src/app/xfa_fftextedit.cpp b/xfa/src/fxfa/src/app/xfa_fftextedit.cpp
index d04a561b4c..3cf94523c1 100644
--- a/xfa/src/fxfa/src/app/xfa_fftextedit.cpp
+++ b/xfa/src/fxfa/src/app/xfa_fftextedit.cpp
@@ -346,7 +346,7 @@ FX_BOOL CXFA_FFTextEdit::GetSuggestWords(CFX_PointF pointf, CFX_ByteStringArray
FWLToClient(pointf.x, pointf.y);
return ((CFWL_Edit*)m_pNormalWidget)->GetSuggestWords(pointf, sSuggest);
}
-FX_BOOL CXFA_FFTextEdit::ReplaceSpellCheckWord(CFX_PointF pointf, FX_BSTR bsReplace)
+FX_BOOL CXFA_FFTextEdit::ReplaceSpellCheckWord(CFX_PointF pointf, const CFX_ByteStringC& bsReplace)
{
if (m_pDataAcc->GetUIType() != XFA_ELEMENT_TextEdit) {
return FALSE;
@@ -390,14 +390,14 @@ void CXFA_FFTextEdit::OnAddDoRecord(IFWL_Widget *pWidget)
{
GetDoc()->GetDocProvider()->AddDoRecord(this);
}
-FX_BOOL CXFA_FFTextEdit::CheckWord(FX_BSTR sWord)
+FX_BOOL CXFA_FFTextEdit::CheckWord(const CFX_ByteStringC& sWord)
{
if (sWord.IsEmpty() || m_pDataAcc->GetUIType() != XFA_ELEMENT_TextEdit) {
return TRUE;
}
return GetDoc()->GetDocProvider()->CheckWord(GetDoc(), sWord);
}
-FX_BOOL CXFA_FFTextEdit::GetSuggestWords(FX_BSTR sWord, CFX_ByteStringArray &sSuggest)
+FX_BOOL CXFA_FFTextEdit::GetSuggestWords(const CFX_ByteStringC& sWord, CFX_ByteStringArray &sSuggest)
{
if (m_pDataAcc->GetUIType() != XFA_ELEMENT_TextEdit) {
return FALSE;
diff --git a/xfa/src/fxfa/src/app/xfa_fftextedit.h b/xfa/src/fxfa/src/app/xfa_fftextedit.h
index ece1a4b9e3..cd2dae24a9 100644
--- a/xfa/src/fxfa/src/app/xfa_fftextedit.h
+++ b/xfa/src/fxfa/src/app/xfa_fftextedit.h
@@ -33,7 +33,7 @@ public:
virtual FX_BOOL Delete();
virtual FX_BOOL DeSelect();
FX_BOOL GetSuggestWords(CFX_PointF pointf, CFX_ByteStringArray &sSuggest);
- FX_BOOL ReplaceSpellCheckWord(CFX_PointF pointf, FX_BSTR bsReplace);
+ FX_BOOL ReplaceSpellCheckWord(CFX_PointF pointf, const CFX_ByteStringC& bsReplace);
protected:
FX_DWORD GetAlignment();
virtual FX_BOOL CommitData();
@@ -45,8 +45,8 @@ public:
void OnTextChanged(IFWL_Widget *pWidget, const CFX_WideString &wsChanged, const CFX_WideString &wsPrevText);
void OnTextFull(IFWL_Widget *pWidget);
void OnAddDoRecord(IFWL_Widget *pWidget);
- FX_BOOL CheckWord(FX_BSTR sWord);
- FX_BOOL GetSuggestWords(FX_BSTR sWord, CFX_ByteStringArray &sSuggest);
+ FX_BOOL CheckWord(const CFX_ByteStringC& sWord);
+ FX_BOOL GetSuggestWords(const CFX_ByteStringC& sWord, CFX_ByteStringArray &sSuggest);
virtual int32_t OnProcessMessage(CFWL_Message *pMessage);
virtual FWL_ERR OnProcessEvent(CFWL_Event *pEvent);
virtual FWL_ERR OnDrawWidget(CFX_Graphics *pGraphics, const CFX_Matrix *pMatrix = NULL);
diff --git a/xfa/src/fxfa/src/app/xfa_ffwidget.cpp b/xfa/src/fxfa/src/app/xfa_ffwidget.cpp
index be1418169f..b0cec0b9af 100644
--- a/xfa/src/fxfa/src/app/xfa_ffwidget.cpp
+++ b/xfa/src/fxfa/src/app/xfa_ffwidget.cpp
@@ -938,7 +938,7 @@ FX_CHAR* XFA_Base64Encode(const uint8_t* buf, int32_t buf_len)
out[j] = '\0';
return out;
}
-FXCODEC_IMAGE_TYPE XFA_GetImageType(FX_WSTR wsType)
+FXCODEC_IMAGE_TYPE XFA_GetImageType(const CFX_WideStringC& wsType)
{
CFX_WideString wsContentType(wsType);
wsContentType.MakeLower();
diff --git a/xfa/src/fxfa/src/app/xfa_ffwidget.h b/xfa/src/fxfa/src/app/xfa_ffwidget.h
index b1d33bb94b..c45def90e9 100644
--- a/xfa/src/fxfa/src/app/xfa_ffwidget.h
+++ b/xfa/src/fxfa/src/app/xfa_ffwidget.h
@@ -146,7 +146,7 @@ public:
{
return FALSE;
}
- virtual FX_BOOL ReplaceSpellCheckWord(CFX_PointF pointf, FX_BSTR bsReplace)
+ virtual FX_BOOL ReplaceSpellCheckWord(CFX_PointF pointf, const CFX_ByteStringC& bsReplace)
{
return FALSE;
}
@@ -193,7 +193,7 @@ CFX_GraphStateData::LineCap XFA_LineCapToFXGE(int32_t iLineCap);
void XFA_DrawImage(CFX_Graphics* pGS, const CFX_RectF &rtImage, CFX_Matrix* pMatrix, CFX_DIBitmap* pDIBitmap, int32_t iAspect, int32_t iImageXDpi, int32_t iImageYDpi, int32_t iHorzAlign = XFA_ATTRIBUTEENUM_Left, int32_t iVertAlign = XFA_ATTRIBUTEENUM_Top);
CFX_DIBitmap* XFA_LoadImageData(CXFA_FFDoc *pDoc, CXFA_Image *pImage, FX_BOOL &bNameImage, int32_t &iImageXDpi, int32_t &iImageYDpi);
CFX_DIBitmap* XFA_LoadImageFromBuffer(IFX_FileRead* pImageFileRead, FXCODEC_IMAGE_TYPE type, int32_t &iImageXDpi, int32_t &iImageYDpi);
-FXCODEC_IMAGE_TYPE XFA_GetImageType(FX_WSTR wsType);
+FXCODEC_IMAGE_TYPE XFA_GetImageType(const CFX_WideStringC& wsType);
FX_CHAR* XFA_Base64Encode(const uint8_t* buf, int32_t buf_len);
void XFA_RectWidthoutMargin(CFX_RectF &rt, const CXFA_Margin &mg, FX_BOOL bUI = FALSE);
FX_FLOAT XFA_GetEdgeThickness(const CXFA_StrokeArray &strokes, FX_BOOL b3DStyle, int32_t nIndex);
diff --git a/xfa/src/fxfa/src/app/xfa_ffwidgetacc.cpp b/xfa/src/fxfa/src/app/xfa_ffwidgetacc.cpp
index e12a50e8e5..405e58e14c 100644
--- a/xfa/src/fxfa/src/app/xfa_ffwidgetacc.cpp
+++ b/xfa/src/fxfa/src/app/xfa_ffwidgetacc.cpp
@@ -296,7 +296,7 @@ void CXFA_WidgetAcc::ResetData()
break;
}
}
-void CXFA_WidgetAcc::SetImageEdit(FX_WSTR wsContentType, FX_WSTR wsHref, FX_WSTR wsData)
+void CXFA_WidgetAcc::SetImageEdit(const CFX_WideStringC& wsContentType, const CFX_WideStringC& wsHref, const CFX_WideStringC& wsData)
{
CXFA_Image image = GetFormValue().GetImage();
if (image) {
diff --git a/xfa/src/fxfa/src/app/xfa_ffwidgethandler.cpp b/xfa/src/fxfa/src/app/xfa_ffwidgethandler.cpp
index cdaaeccd6e..348fe3d621 100644
--- a/xfa/src/fxfa/src/app/xfa_ffwidgethandler.cpp
+++ b/xfa/src/fxfa/src/app/xfa_ffwidgethandler.cpp
@@ -585,7 +585,7 @@ FX_BOOL CXFA_FFMenuHandler::GetSuggestWords(IXFA_Widget* hWidget, CFX_PointF poi
{
return static_cast<CXFA_FFWidget*>(hWidget)->GetSuggestWords(pointf, sSuggest);
}
-FX_BOOL CXFA_FFMenuHandler::ReplaceSpellCheckWord(IXFA_Widget* hWidget, CFX_PointF pointf, FX_BSTR bsReplace)
+FX_BOOL CXFA_FFMenuHandler::ReplaceSpellCheckWord(IXFA_Widget* hWidget, CFX_PointF pointf, const CFX_ByteStringC& bsReplace)
{
return static_cast<CXFA_FFWidget*>(hWidget)->ReplaceSpellCheckWord(pointf, bsReplace);
}
diff --git a/xfa/src/fxfa/src/app/xfa_ffwidgethandler.h b/xfa/src/fxfa/src/app/xfa_ffwidgethandler.h
index bc4afce02d..4477f1f10e 100644
--- a/xfa/src/fxfa/src/app/xfa_ffwidgethandler.h
+++ b/xfa/src/fxfa/src/app/xfa_ffwidgethandler.h
@@ -99,6 +99,6 @@ public:
virtual FX_BOOL Undo(IXFA_Widget* hWidget);
virtual FX_BOOL Redo(IXFA_Widget* hWidget);
virtual FX_BOOL GetSuggestWords(IXFA_Widget* hWidget, CFX_PointF pointf, CFX_ByteStringArray &sSuggest);
- virtual FX_BOOL ReplaceSpellCheckWord(IXFA_Widget* hWidget, CFX_PointF pointf, FX_BSTR bsReplace);
+ virtual FX_BOOL ReplaceSpellCheckWord(IXFA_Widget* hWidget, CFX_PointF pointf, const CFX_ByteStringC& bsReplace);
};
#endif
diff --git a/xfa/src/fxfa/src/app/xfa_fontmgr.cpp b/xfa/src/fxfa/src/app/xfa_fontmgr.cpp
index db1742b788..88926bdaa8 100644
--- a/xfa/src/fxfa/src/app/xfa_fontmgr.cpp
+++ b/xfa/src/fxfa/src/app/xfa_fontmgr.cpp
@@ -961,7 +961,7 @@ static const XFA_FONTINFO g_XFAFontsMap[] = {
{0xfef135f8, L"AdobeHeitiStd-Regular", L"Droid Sans Fallback", 0, 936},
};
#endif
-void XFA_LocalFontNameToEnglishName(FX_WSTR wsLocalName, CFX_WideString &wsEnglishName)
+void XFA_LocalFontNameToEnglishName(const CFX_WideStringC& wsLocalName, CFX_WideString &wsEnglishName)
{
wsEnglishName = wsLocalName;
#if _FXM_PLATFORM_ == _FXM_PLATFORM_WINDOWS_ || _FXM_PLATFORM_ == _FXM_PLATFORM_LINUX_ || _FXM_PLATFORM_ == _FXM_PLATFORM_APPLE_ || _FXM_PLATFORM_ == _FXM_PLATFORM_ANDROID_
@@ -983,7 +983,7 @@ void XFA_LocalFontNameToEnglishName(FX_WSTR wsLocalName, CFX_WideString &wsEngli
} while (iEnd >= iStart);
#endif
}
-const XFA_FONTINFO* XFA_GetFontINFOByFontName(FX_WSTR wsFontName)
+const XFA_FONTINFO* XFA_GetFontINFOByFontName(const CFX_WideStringC& wsFontName)
{
#if _FXM_PLATFORM_ == _FXM_PLATFORM_WINDOWS_ || _FXM_PLATFORM_ == _FXM_PLATFORM_LINUX_ || _FXM_PLATFORM_ == _FXM_PLATFORM_APPLE_ || _FXM_PLATFORM_ == _FXM_PLATFORM_ANDROID_
CFX_WideString wsFontNameTemp = wsFontName;
@@ -1028,7 +1028,7 @@ CXFA_DefFontMgr::~CXFA_DefFontMgr()
m_CacheFonts.RemoveAll();
}
#define _FXFA_USEGASFONTMGR_
-IFX_Font* CXFA_DefFontMgr::GetFont(IXFA_Doc* hDoc, FX_WSTR wsFontFamily, FX_DWORD dwFontStyles, FX_WORD wCodePage )
+IFX_Font* CXFA_DefFontMgr::GetFont(IXFA_Doc* hDoc, const CFX_WideStringC& wsFontFamily, FX_DWORD dwFontStyles, FX_WORD wCodePage )
{
CFX_WideString wsFontName = wsFontFamily;
IFX_FontMgr* pFDEFontMgr = ((CXFA_FFDoc*)hDoc)->GetApp()->GetFDEFontMgr();
@@ -1081,7 +1081,7 @@ IFX_Font* CXFA_DefFontMgr::GetFont(IXFA_Doc* hDoc, FX_WSTR wsFontFamily, FX_DWOR
}
return pFont;
}
-IFX_Font* CXFA_DefFontMgr::GetDefaultFont(IXFA_Doc* hDoc, FX_WSTR wsFontFamily, FX_DWORD dwFontStyles, FX_WORD wCodePage)
+IFX_Font* CXFA_DefFontMgr::GetDefaultFont(IXFA_Doc* hDoc, const CFX_WideStringC& wsFontFamily, FX_DWORD dwFontStyles, FX_WORD wCodePage)
{
IFX_FontMgr* pFDEFontMgr = ((CXFA_FFDoc*)hDoc)->GetApp()->GetFDEFontMgr();
#ifdef _FXFA_USEGASFONTMGR_
@@ -1181,7 +1181,7 @@ IFX_Font* CXFA_PDFFontMgr::FindFont(CFX_ByteString strPsName, FX_BOOL bBold, FX_
}
return NULL;
}
-IFX_Font* CXFA_PDFFontMgr::GetFont(FX_WSTR wsFontFamily, FX_DWORD dwFontStyles, CPDF_Font** pPDFFont, FX_BOOL bStrictMatch )
+IFX_Font* CXFA_PDFFontMgr::GetFont(const CFX_WideStringC& wsFontFamily, FX_DWORD dwFontStyles, CPDF_Font** pPDFFont, FX_BOOL bStrictMatch )
{
FX_DWORD dwHashCode = FX_HashCode_String_GetW(wsFontFamily.GetPtr(), wsFontFamily.GetLength());
CFX_ByteString strKey;
@@ -1213,7 +1213,7 @@ CFX_ByteString CXFA_PDFFontMgr::PsNameToFontName(const CFX_ByteString& strPsName
}
return strPsName;
}
-FX_BOOL CXFA_PDFFontMgr::PsNameMatchDRFontName(FX_BSTR bsPsName, FX_BOOL bBold, FX_BOOL bItalic, const CFX_ByteString& bsDRFontName, FX_BOOL bStrictMatch)
+FX_BOOL CXFA_PDFFontMgr::PsNameMatchDRFontName(const CFX_ByteStringC& bsPsName, FX_BOOL bBold, FX_BOOL bItalic, const CFX_ByteString& bsDRFontName, FX_BOOL bStrictMatch)
{
CFX_ByteString bsDRName = bsDRFontName;
bsDRName.Remove('-');
@@ -1305,7 +1305,7 @@ CXFA_FontMgr::~CXFA_FontMgr()
{
DelAllMgrMap();
}
-IFX_Font* CXFA_FontMgr::GetFont(IXFA_Doc* hDoc, FX_WSTR wsFontFamily, FX_DWORD dwFontStyles,
+IFX_Font* CXFA_FontMgr::GetFont(IXFA_Doc* hDoc, const CFX_WideStringC& wsFontFamily, FX_DWORD dwFontStyles,
FX_WORD wCodePage )
{
FX_DWORD dwHash = FX_HashCode_String_GetW(wsFontFamily.GetPtr(), wsFontFamily.GetLength(), FALSE);
diff --git a/xfa/src/fxfa/src/app/xfa_fontmgr.h b/xfa/src/fxfa/src/app/xfa_fontmgr.h
index 3a41cea913..d8f77841c5 100644
--- a/xfa/src/fxfa/src/app/xfa_fontmgr.h
+++ b/xfa/src/fxfa/src/app/xfa_fontmgr.h
@@ -18,8 +18,8 @@ class CXFA_DefFontMgr : public IXFA_FontMgr
public:
CXFA_DefFontMgr() {}
~CXFA_DefFontMgr() override;
- virtual IFX_Font* GetFont(IXFA_Doc* hDoc, FX_WSTR wsFontFamily, FX_DWORD dwFontStyles, FX_WORD wCodePage = 0xFFFF);
- virtual IFX_Font* GetDefaultFont(IXFA_Doc* hDoc, FX_WSTR wsFontFamily, FX_DWORD dwFontStyles, FX_WORD wCodePage = 0xFFFF);
+ virtual IFX_Font* GetFont(IXFA_Doc* hDoc, const CFX_WideStringC& wsFontFamily, FX_DWORD dwFontStyles, FX_WORD wCodePage = 0xFFFF);
+ virtual IFX_Font* GetDefaultFont(IXFA_Doc* hDoc, const CFX_WideStringC& wsFontFamily, FX_DWORD dwFontStyles, FX_WORD wCodePage = 0xFFFF);
protected:
CFX_PtrArray m_CacheFonts;
};
@@ -28,13 +28,13 @@ class CXFA_PDFFontMgr : public IFX_FontProvider
public:
CXFA_PDFFontMgr(CXFA_FFDoc* pDoc);
~CXFA_PDFFontMgr();
- IFX_Font* GetFont(FX_WSTR wsFontFamily, FX_DWORD dwFontStyles, CPDF_Font** pPDFFont, FX_BOOL bStrictMatch = TRUE);
+ IFX_Font* GetFont(const CFX_WideStringC& wsFontFamily, FX_DWORD dwFontStyles, CPDF_Font** pPDFFont, FX_BOOL bStrictMatch = TRUE);
FX_BOOL GetCharWidth(IFX_Font* pFont, FX_WCHAR wUnicode, int32_t &iWidth, FX_BOOL bCharCode);
CFX_MapPtrToPtr m_FDE2PDFFont;
protected:
IFX_Font* FindFont(CFX_ByteString strFamilyName, FX_BOOL bBold, FX_BOOL bItalic, CPDF_Font** pPDFFont, FX_BOOL bStrictMatch = TRUE);
CFX_ByteString PsNameToFontName(const CFX_ByteString& strPsName, FX_BOOL bBold, FX_BOOL bItalic);
- FX_BOOL PsNameMatchDRFontName(FX_BSTR bsPsName, FX_BOOL bBold, FX_BOOL bItalic, const CFX_ByteString& bsDRFontName, FX_BOOL bStrictMatch = TRUE);
+ FX_BOOL PsNameMatchDRFontName(const CFX_ByteStringC& bsPsName, FX_BOOL bBold, FX_BOOL bItalic, const CFX_ByteString& bsDRFontName, FX_BOOL bStrictMatch = TRUE);
CXFA_FFDoc* m_pDoc;
CFX_CMapByteStringToPtr m_FontArray;
};
@@ -43,7 +43,7 @@ class CXFA_FontMgr
public:
CXFA_FontMgr();
~CXFA_FontMgr();
- IFX_Font* GetFont(IXFA_Doc* hDoc, FX_WSTR wsFontFamily, FX_DWORD dwFontStyles,
+ IFX_Font* GetFont(IXFA_Doc* hDoc, const CFX_WideStringC& wsFontFamily, FX_DWORD dwFontStyles,
FX_WORD wCodePage = 0xFFFF);
void LoadDocFonts(IXFA_Doc* hDoc);
void ReleaseDocFonts(IXFA_Doc* hDoc);
diff --git a/xfa/src/fxfa/src/app/xfa_fwladapter.h b/xfa/src/fxfa/src/app/xfa_fwladapter.h
index 1ddfcf4113..62975ff0da 100644
--- a/xfa/src/fxfa/src/app/xfa_fwladapter.h
+++ b/xfa/src/fxfa/src/app/xfa_fwladapter.h
@@ -36,11 +36,11 @@ public:
return CXFA_Edge(NULL);
}
virtual void GetUIMargin(CFX_RectF &rtMargin) {}
- virtual FX_BOOL CheckWord(FX_BSTR sWord)
+ virtual FX_BOOL CheckWord(const CFX_ByteStringC& sWord)
{
return TRUE;
}
- virtual FX_BOOL GetSuggestWords(FX_BSTR sWord, CFX_ByteStringArray &sSuggest)
+ virtual FX_BOOL GetSuggestWords(const CFX_ByteStringC& sWord, CFX_ByteStringArray &sSuggest)
{
return FALSE;
}
diff --git a/xfa/src/fxfa/src/common/xfa_document.h b/xfa/src/fxfa/src/common/xfa_document.h
index 6ef3fd776c..20b8e1a020 100644
--- a/xfa/src/fxfa/src/common/xfa_document.h
+++ b/xfa/src/fxfa/src/common/xfa_document.h
@@ -121,7 +121,7 @@ public:
}
IXFA_Notify* GetNotify() const;
void SetRoot(CXFA_Node* pNewRoot);
- CXFA_Object* GetXFANode(FX_WSTR wsNodeName);
+ CXFA_Object* GetXFANode(const CFX_WideStringC& wsNodeName);
CXFA_Object* GetXFANode(FX_DWORD wsNodeNameHash);
void AddPurgeNode(CXFA_Node *pNode);
FX_BOOL RemovePurgeNode(CXFA_Node *pNode);
@@ -141,7 +141,7 @@ public:
virtual CXFA_Node* CreateNode(FX_DWORD dwPacket, XFA_ELEMENT eElement);
virtual CXFA_Node* CreateNode(XFA_LPCPACKETINFO pPacket, XFA_ELEMENT eElement);
void DoProtoMerge();
- CXFA_Node* GetNodeByID(CXFA_Node* pRoot, FX_WSTR wsID);
+ CXFA_Node* GetNodeByID(CXFA_Node* pRoot, const CFX_WideStringC& wsID);
void DoDataMerge();
void DoDataRemerge(FX_BOOL bDoDataMerge);
diff --git a/xfa/src/fxfa/src/common/xfa_fm2jsapi.h b/xfa/src/fxfa/src/common/xfa_fm2jsapi.h
index 511b1b7a1a..41fee6d133 100644
--- a/xfa/src/fxfa/src/common/xfa_fm2jsapi.h
+++ b/xfa/src/fxfa/src/common/xfa_fm2jsapi.h
@@ -14,7 +14,7 @@ extern "C"
typedef struct XFA_HFM2JSCONTEXT_ {
void** pData;
}* XFA_HFM2JSCONTEXT;
-int32_t XFA_FM2JS_Translate(FX_WSTR wsFormcalc, CFX_WideTextBuf& wsJavascript, CFX_WideString& wsError);
+int32_t XFA_FM2JS_Translate(const CFX_WideStringC& wsFormcalc, CFX_WideTextBuf& wsJavascript, CFX_WideString& wsError);
XFA_HFM2JSCONTEXT XFA_FM2JS_ContextCreate();
void XFA_FM2JS_ContextInitialize(XFA_HFM2JSCONTEXT hFM2JSContext, FXJSE_HRUNTIME hScriptRuntime,
FXJSE_HCONTEXT hScriptContext,
diff --git a/xfa/src/fxfa/src/common/xfa_localemgr.h b/xfa/src/fxfa/src/common/xfa_localemgr.h
index ff3ab3927f..14981ca418 100644
--- a/xfa/src/fxfa/src/common/xfa_localemgr.h
+++ b/xfa/src/fxfa/src/common/xfa_localemgr.h
@@ -33,7 +33,7 @@ public:
virtual FX_WORD GetDefLocaleID();
virtual IFX_Locale* GetDefLocale();
virtual IFX_Locale* GetLocale(FX_WORD lcid);
- virtual IFX_Locale* GetLocaleByName(FX_WSTR wsLocaleName);
+ virtual IFX_Locale* GetLocaleByName(const CFX_WideStringC& wsLocaleName);
~CXFA_LocaleMgr();
void SetDefLocale(IFX_Locale* pLocale);
CFX_WideStringC GetConfigLocaleName(CXFA_Node* pConfig);
diff --git a/xfa/src/fxfa/src/common/xfa_object.h b/xfa/src/fxfa/src/common/xfa_object.h
index 4d2c764457..69c80da73e 100644
--- a/xfa/src/fxfa/src/common/xfa_object.h
+++ b/xfa/src/fxfa/src/common/xfa_object.h
@@ -163,11 +163,11 @@ public:
CXFA_Node* GetModelNode();
void UpdateNameHash();
FX_BOOL HasAttribute(XFA_ATTRIBUTE eAttr, FX_BOOL bCanInherit = FALSE);
- FX_BOOL SetAttribute(XFA_ATTRIBUTE eAttr, FX_WSTR wsValue, FX_BOOL bNotify = FALSE);
+ FX_BOOL SetAttribute(XFA_ATTRIBUTE eAttr, const CFX_WideStringC& wsValue, FX_BOOL bNotify = FALSE);
FX_BOOL GetAttribute(XFA_ATTRIBUTE eAttr, CFX_WideString &wsValue, FX_BOOL bUseDefault = TRUE);
- FX_BOOL SetAttribute(FX_WSTR wsAttr, FX_WSTR wsValue, FX_BOOL bNotify = FALSE);
- FX_BOOL GetAttribute(FX_WSTR wsAttr, CFX_WideString &wsValue, FX_BOOL bUseDefault = TRUE);
- FX_BOOL RemoveAttribute(FX_WSTR wsAttr);
+ FX_BOOL SetAttribute(const CFX_WideStringC& wsAttr, const CFX_WideStringC& wsValue, FX_BOOL bNotify = FALSE);
+ FX_BOOL GetAttribute(const CFX_WideStringC& wsAttr, CFX_WideString &wsValue, FX_BOOL bUseDefault = TRUE);
+ FX_BOOL RemoveAttribute(const CFX_WideStringC& wsAttr);
FX_BOOL SetContent(const CFX_WideString& wsContent, const CFX_WideString& wsXMLValue, FX_BOOL bNotify = FALSE, FX_BOOL bScriptModify = FALSE, FX_BOOL bSyncData = TRUE);
FX_BOOL TryContent(CFX_WideString& wsContent, FX_BOOL bScriptModify = FALSE, FX_BOOL bProto = TRUE);
CFX_WideString GetContent();
@@ -259,11 +259,11 @@ public:
CXFA_WidgetData* GetContainerWidgetData();
FX_BOOL GetLocaleName(CFX_WideString& wsLocaleName);
XFA_ATTRIBUTEENUM GetIntact();
- CXFA_Node* GetFirstChildByName(FX_WSTR wsNodeName) const;
+ CXFA_Node* GetFirstChildByName(const CFX_WideStringC& wsNodeName) const;
CXFA_Node* GetFirstChildByName(FX_DWORD dwNodeNameHash) const;
CXFA_Node* GetFirstChildByClass(XFA_ELEMENT eNodeClass) const;
CXFA_Node* GetNextSameNameSibling(FX_DWORD dwNodeNameHash) const;
- CXFA_Node* GetNextSameNameSibling(FX_WSTR wsNodeName) const;
+ CXFA_Node* GetNextSameNameSibling(const CFX_WideStringC& wsNodeName) const;
CXFA_Node* GetNextSameClassSibling(XFA_ELEMENT eNodeClass) const;
int32_t GetNodeSameNameIndex() const;
int32_t GetNodeSameClassIndex() const;
@@ -434,13 +434,13 @@ protected:
void OnRemoved(CXFA_Node *pParent, CXFA_Node *pRemoved, FX_BOOL bNotify);
void OnChanging(XFA_ATTRIBUTE eAttr, void* pNewValue, FX_BOOL bNotify);
void OnChanged(XFA_ATTRIBUTE eAttr, void* pNewValue, FX_BOOL bNotify, FX_BOOL bScriptModify = FALSE);
- int32_t execSingleEventByName(FX_WSTR wsEventName, XFA_ELEMENT eElementType);
+ int32_t execSingleEventByName(const CFX_WideStringC& wsEventName, XFA_ELEMENT eElementType);
FX_BOOL SetScriptContent(const CFX_WideString& wsContent, const CFX_WideString& wsXMLValue, FX_BOOL bNotify = TRUE, FX_BOOL bScriptModify = FALSE, FX_BOOL bSyncData = TRUE);
CFX_WideString GetScriptContent(FX_BOOL bScriptModify = FALSE);
XFA_LPMAPMODULEDATA GetMapModuleData(FX_BOOL bCreateNew);
void SetMapModuleValue(void* pKey, void* pValue);
FX_BOOL GetMapModuleValue(void* pKey, void* &pValue);
- void SetMapModuleString(void* pKey, FX_WSTR wsValue);
+ void SetMapModuleString(void* pKey, const CFX_WideStringC& wsValue);
FX_BOOL GetMapModuleString(void* pKey, CFX_WideStringC &wsValue);
void SetMapModuleBuffer(void* pKey, void* pValue, int32_t iBytes, XFA_MAPDATABLOCKCALLBACKINFO* pCallbackInfo = NULL);
FX_BOOL GetMapModuleBuffer(void* pKey, void* &pValue, int32_t &iBytes, FX_BOOL bProtoAlso = TRUE);
@@ -510,7 +510,7 @@ public:
{
return XFA_ELEMENT_NodeList;
}
- CXFA_Node* NamedItem(FX_WSTR wsName);
+ CXFA_Node* NamedItem(const CFX_WideStringC& wsName);
virtual int32_t GetLength() = 0;
virtual FX_BOOL Append(CXFA_Node* pNode) = 0;
virtual FX_BOOL Insert(CXFA_Node* pNewNode, CXFA_Node* pBeforeNode) = 0;
diff --git a/xfa/src/fxfa/src/common/xfa_script.h b/xfa/src/fxfa/src/common/xfa_script.h
index d4c867aa31..c7f18071ac 100644
--- a/xfa/src/fxfa/src/common/xfa_script.h
+++ b/xfa/src/fxfa/src/common/xfa_script.h
@@ -84,8 +84,8 @@ public:
virtual void SetEventParam(CXFA_EventParam* pEventParam) = 0;
virtual CXFA_EventParam* GetEventParam() = 0;
- virtual FX_BOOL RunScript(XFA_SCRIPTLANGTYPE eScriptType, FX_WSTR wsScript, FXJSE_HVALUE hRetValue, CXFA_Object* pThisObject = NULL) = 0;
- virtual int32_t ResolveObjects(CXFA_Object* refNode, FX_WSTR wsExpression, XFA_RESOLVENODE_RS& resolveNodeRS, FX_DWORD dwStyles = XFA_RESOLVENODE_Children, CXFA_Node* bindNode = NULL) = 0;
+ virtual FX_BOOL RunScript(XFA_SCRIPTLANGTYPE eScriptType, const CFX_WideStringC& wsScript, FXJSE_HVALUE hRetValue, CXFA_Object* pThisObject = NULL) = 0;
+ virtual int32_t ResolveObjects(CXFA_Object* refNode, const CFX_WideStringC& wsExpression, XFA_RESOLVENODE_RS& resolveNodeRS, FX_DWORD dwStyles = XFA_RESOLVENODE_Children, CXFA_Node* bindNode = NULL) = 0;
virtual FXJSE_HVALUE GetJSValueFromMap(CXFA_Object* pObject) = 0;
virtual void CacheList(CXFA_NodeList* pList) = 0;
virtual CXFA_Object* GetThisObject() const = 0;
diff --git a/xfa/src/fxfa/src/common/xfa_utils.h b/xfa/src/fxfa/src/common/xfa_utils.h
index 191fcf2bbb..11a1c0e2d8 100644
--- a/xfa/src/fxfa/src/common/xfa_utils.h
+++ b/xfa/src/fxfa/src/common/xfa_utils.h
@@ -6,7 +6,7 @@
#ifndef _XFA_UTILS_H_
#define _XFA_UTILS_H_
-FX_BOOL XFA_FDEExtension_ResolveNamespaceQualifier(IFDE_XMLElement* pNode, FX_WSTR wsQualifier, CFX_WideString& wsNamespaceURI);
+FX_BOOL XFA_FDEExtension_ResolveNamespaceQualifier(IFDE_XMLElement* pNode, const CFX_WideStringC& wsQualifier, CFX_WideString& wsNamespaceURI);
template <class NodeType, class TraverseStrategy>
class CXFA_NodeIteratorTemplate
{
@@ -220,7 +220,7 @@ CXFA_Node* XFA_CreateUIChild(CXFA_Node* pNode, XFA_ELEMENT& eWidgetType
CXFA_LocaleValue XFA_GetLocaleValue(CXFA_WidgetData* pWidgetData);
CFX_WideString XFA_NumericLimit(const CFX_WideString &wsValue, int32_t iLead, int32_t iTread);
FX_DOUBLE XFA_WideStringToDouble(const CFX_WideString &wsStringVal);
-FX_DOUBLE XFA_ByteStringToDouble(FX_BSTR szStringVal);
+FX_DOUBLE XFA_ByteStringToDouble(const CFX_ByteStringC& szStringVal);
int32_t XFA_MapRotation(int32_t nRotation);
#ifndef XFA_PARSE_HAS_LINEIDENTIFIER
#define XFA_PARSE_HAS_LINEIDENTIFIER
diff --git a/xfa/src/fxfa/src/fm2js/xfa_expression.cpp b/xfa/src/fxfa/src/fm2js/xfa_expression.cpp
index 47e5cb440f..b01b11f723 100644
--- a/xfa/src/fxfa/src/fm2js/xfa_expression.cpp
+++ b/xfa/src/fxfa/src/fm2js/xfa_expression.cpp
@@ -19,7 +19,7 @@ void CXFA_FMExpression::ToJavaScript(CFX_WideTextBuf& javascript)
{}
void CXFA_FMExpression::ToImpliedReturnJS(CFX_WideTextBuf& javascript)
{}
-CXFA_FMFunctionDefinition::CXFA_FMFunctionDefinition( FX_DWORD line, FX_BOOL isGlobal, FX_WSTR wsName, CFX_WideStringCArray *pArguments, CFX_PtrArray *pExpressions )
+CXFA_FMFunctionDefinition::CXFA_FMFunctionDefinition( FX_DWORD line, FX_BOOL isGlobal, const CFX_WideStringC& wsName, CFX_WideStringCArray *pArguments, CFX_PtrArray *pExpressions )
: CXFA_FMExpression(line, XFA_FM_EXPTYPE_FUNC),
m_isGlobal(isGlobal),
m_wsName(wsName),
@@ -117,7 +117,7 @@ void CXFA_FMFunctionDefinition::ToJavaScript(CFX_WideTextBuf& javascript)
}
void CXFA_FMFunctionDefinition::ToImpliedReturnJS(CFX_WideTextBuf&)
{}
-CXFA_FMVarExpression::CXFA_FMVarExpression( FX_DWORD line, FX_WSTR wsName, CXFA_FMExpression *pInit )
+CXFA_FMVarExpression::CXFA_FMVarExpression( FX_DWORD line, const CFX_WideStringC& wsName, CXFA_FMExpression *pInit )
: CXFA_FMExpression(line, XFA_FM_EXPTYPE_VAR),
m_wsName(wsName),
m_pInit(pInit)
@@ -451,7 +451,7 @@ void CXFA_FMContinueExpression::ToImpliedReturnJS(CFX_WideTextBuf& javascript)
javascript << FX_WSTRC(L" = 0;\n");
javascript << FX_WSTRC(L"continue;\n");
}
-CXFA_FMForExpression::CXFA_FMForExpression(FX_DWORD line, FX_WSTR wsVariant, CXFA_FMSimpleExpression *pAssignment, CXFA_FMSimpleExpression *pAccessor, int32_t iDirection, CXFA_FMSimpleExpression *pStep, CXFA_FMExpression *pList)
+CXFA_FMForExpression::CXFA_FMForExpression(FX_DWORD line, const CFX_WideStringC& wsVariant, CXFA_FMSimpleExpression *pAssignment, CXFA_FMSimpleExpression *pAccessor, int32_t iDirection, CXFA_FMSimpleExpression *pStep, CXFA_FMExpression *pList)
: CXFA_FMLoopExpression(line),
m_wsVariant(wsVariant),
m_pAssignment(pAssignment),
@@ -580,7 +580,7 @@ void CXFA_FMForExpression::ToImpliedReturnJS(CFX_WideTextBuf& javascript)
m_pList->ToImpliedReturnJS(javascript);
javascript << FX_WSTRC(L"}\n");
}
-CXFA_FMForeachExpression::CXFA_FMForeachExpression( FX_DWORD line, FX_WSTR wsIdentifier, CFX_PtrArray *pAccessors, CXFA_FMExpression *pList )
+CXFA_FMForeachExpression::CXFA_FMForeachExpression( FX_DWORD line, const CFX_WideStringC& wsIdentifier, CFX_PtrArray *pAccessors, CXFA_FMExpression *pList )
: CXFA_FMLoopExpression(line),
m_wsIdentifier(wsIdentifier),
m_pAccessors(pAccessors),
diff --git a/xfa/src/fxfa/src/fm2js/xfa_expression.h b/xfa/src/fxfa/src/fm2js/xfa_expression.h
index a3781fa26d..87fd99d1f8 100644
--- a/xfa/src/fxfa/src/fm2js/xfa_expression.h
+++ b/xfa/src/fxfa/src/fm2js/xfa_expression.h
@@ -39,7 +39,7 @@ protected:
class CXFA_FMFunctionDefinition : public CXFA_FMExpression
{
public:
- CXFA_FMFunctionDefinition(FX_DWORD line, FX_BOOL isGlobal, FX_WSTR wsName, CFX_WideStringCArray *pArguments, CFX_PtrArray *pExpressions);
+ CXFA_FMFunctionDefinition(FX_DWORD line, FX_BOOL isGlobal, const CFX_WideStringC& wsName, CFX_WideStringCArray *pArguments, CFX_PtrArray *pExpressions);
virtual ~CXFA_FMFunctionDefinition();
virtual void ToJavaScript(CFX_WideTextBuf& javascript);
virtual void ToImpliedReturnJS(CFX_WideTextBuf&);
@@ -52,7 +52,7 @@ private:
class CXFA_FMVarExpression : public CXFA_FMExpression
{
public:
- CXFA_FMVarExpression(FX_DWORD line, FX_WSTR wsName, CXFA_FMExpression *pInit);
+ CXFA_FMVarExpression(FX_DWORD line, const CFX_WideStringC& wsName, CXFA_FMExpression *pInit);
virtual ~CXFA_FMVarExpression();
virtual void ToJavaScript(CFX_WideTextBuf& javascript);
virtual void ToImpliedReturnJS(CFX_WideTextBuf&);
@@ -144,7 +144,7 @@ private:
class CXFA_FMForExpression : public CXFA_FMLoopExpression
{
public:
- CXFA_FMForExpression(FX_DWORD line, FX_WSTR wsVariant, CXFA_FMSimpleExpression *pAssignment,
+ CXFA_FMForExpression(FX_DWORD line, const CFX_WideStringC& wsVariant, CXFA_FMSimpleExpression *pAssignment,
CXFA_FMSimpleExpression *pAccessor, int32_t iDirection, CXFA_FMSimpleExpression *pStep, CXFA_FMExpression *pList);
virtual ~CXFA_FMForExpression();
virtual void ToJavaScript(CFX_WideTextBuf& javascript);
@@ -160,7 +160,7 @@ private:
class CXFA_FMForeachExpression : public CXFA_FMLoopExpression
{
public:
- CXFA_FMForeachExpression(FX_DWORD line, FX_WSTR wsIdentifier, CFX_PtrArray *pAccessors, CXFA_FMExpression *pList);
+ CXFA_FMForeachExpression(FX_DWORD line, const CFX_WideStringC& wsIdentifier, CFX_PtrArray *pAccessors, CXFA_FMExpression *pList);
virtual ~CXFA_FMForeachExpression();
virtual void ToJavaScript(CFX_WideTextBuf& javascript);
virtual void ToImpliedReturnJS(CFX_WideTextBuf&);
diff --git a/xfa/src/fxfa/src/fm2js/xfa_fm2jsapi.cpp b/xfa/src/fxfa/src/fm2js/xfa_fm2jsapi.cpp
index 0ffec233dd..42035efd14 100644
--- a/xfa/src/fxfa/src/fm2js/xfa_fm2jsapi.cpp
+++ b/xfa/src/fxfa/src/fm2js/xfa_fm2jsapi.cpp
@@ -9,7 +9,7 @@
extern "C"
{
#endif
-int32_t XFA_FM2JS_Translate(FX_WSTR wsFormcalc, CFX_WideTextBuf& wsJavascript, CFX_WideString& wsError)
+int32_t XFA_FM2JS_Translate(const CFX_WideStringC& wsFormcalc, CFX_WideTextBuf& wsJavascript, CFX_WideString& wsError)
{
if (wsFormcalc.IsEmpty()) {
wsJavascript.Clear();
diff --git a/xfa/src/fxfa/src/fm2js/xfa_fm2jscontext.cpp b/xfa/src/fxfa/src/fm2js/xfa_fm2jscontext.cpp
index 466aaeefbd..2ebc6a21e2 100644
--- a/xfa/src/fxfa/src/fm2js/xfa_fm2jscontext.cpp
+++ b/xfa/src/fxfa/src/fm2js/xfa_fm2jscontext.cpp
@@ -524,7 +524,7 @@ static XFA_FMHtmlReserveCode reservesForEncode [] = {
{9829, L"hearts"},
{9830, L"diams"},
};
-void CXFA_FM2JSContext::Abs(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Abs(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if(args.GetLength() == 1) {
FXJSE_HVALUE argOne = args.GetValue(0);
@@ -543,7 +543,7 @@ void CXFA_FM2JSContext::Abs(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argu
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Abs");
}
}
-void CXFA_FM2JSContext::Avg(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Avg(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -608,7 +608,7 @@ void CXFA_FM2JSContext::Avg(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argu
FXJSE_Value_SetDouble(args.GetReturnValue(), dSum / uCount);
}
}
-void CXFA_FM2JSContext::Ceil(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Ceil(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -624,7 +624,7 @@ void CXFA_FM2JSContext::Ceil(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arg
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Ceil");
}
}
-void CXFA_FM2JSContext::Count(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Count(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -685,7 +685,7 @@ void CXFA_FM2JSContext::Count(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Ar
argValue = 0;
FXJSE_Value_SetInteger(args.GetReturnValue(), (int32_t)uCount);
}
-void CXFA_FM2JSContext::Floor(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Floor(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -701,7 +701,7 @@ void CXFA_FM2JSContext::Floor(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Ar
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Floor");
}
}
-void CXFA_FM2JSContext::Max(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Max(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -801,7 +801,7 @@ void CXFA_FM2JSContext::Max(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argu
FXJSE_Value_SetNull(args.GetReturnValue());
}
}
-void CXFA_FM2JSContext::Min(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Min(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -901,7 +901,7 @@ void CXFA_FM2JSContext::Min(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argu
FXJSE_Value_SetNull(args.GetReturnValue());
}
}
-void CXFA_FM2JSContext::Mod(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Mod(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -981,7 +981,7 @@ void CXFA_FM2JSContext::Mod(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argu
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Mod");
}
}
-void CXFA_FM2JSContext::Round(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Round(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -1083,7 +1083,7 @@ void CXFA_FM2JSContext::Round(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Ar
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Round");
}
}
-void CXFA_FM2JSContext::Sum(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Sum(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -1156,7 +1156,7 @@ void CXFA_FM2JSContext::Sum(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argu
FXJSE_Value_SetDouble(args.GetReturnValue(), dSum);
}
}
-void CXFA_FM2JSContext::Date(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Date(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if (args.GetLength() == 0) {
struct tm *pTmStruct = 0;
@@ -1177,7 +1177,7 @@ void CXFA_FM2JSContext::Date(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arg
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Date");
}
}
-void CXFA_FM2JSContext::Date2Num(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Date2Num(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if ((argc > 0) && (argc < 4)) {
@@ -1232,7 +1232,7 @@ void CXFA_FM2JSContext::Date2Num(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Date2Num");
}
}
-void CXFA_FM2JSContext::DateFmt(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::DateFmt(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if (argc < 3) {
@@ -1280,7 +1280,7 @@ void CXFA_FM2JSContext::DateFmt(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Date2Num");
}
}
-void CXFA_FM2JSContext::IsoDate2Num(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::IsoDate2Num(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if(args.GetLength() == 1) {
FXJSE_HVALUE argOne = GetSimpleHValue(hThis, args, 0);
@@ -1298,7 +1298,7 @@ void CXFA_FM2JSContext::IsoDate2Num(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFX
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"IsoDate2Num");
}
}
-void CXFA_FM2JSContext::IsoTime2Num(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::IsoTime2Num(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
if(args.GetLength() == 1) {
@@ -1349,7 +1349,7 @@ void CXFA_FM2JSContext::IsoTime2Num(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFX
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"IsoTime2Num");
}
}
-void CXFA_FM2JSContext::LocalDateFmt(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::LocalDateFmt(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if (argc < 3) {
@@ -1397,7 +1397,7 @@ void CXFA_FM2JSContext::LocalDateFmt(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CF
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"LocalDateFmt");
}
}
-void CXFA_FM2JSContext::LocalTimeFmt(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::LocalTimeFmt(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if (argc < 3) {
@@ -1445,7 +1445,7 @@ void CXFA_FM2JSContext::LocalTimeFmt(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CF
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"LocalTimeFmt");
}
}
-void CXFA_FM2JSContext::Num2Date(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Num2Date(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if ((argc > 0) && (argc < 4)) {
@@ -1593,7 +1593,7 @@ void CXFA_FM2JSContext::Num2Date(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Num2Date");
}
}
-void CXFA_FM2JSContext::Num2GMTime(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Num2GMTime(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if ((argc > 0) && (argc < 4)) {
@@ -1650,7 +1650,7 @@ void CXFA_FM2JSContext::Num2GMTime(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJ
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Num2GMTime");
}
}
-void CXFA_FM2JSContext::Num2Time(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Num2Time(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if ((argc > 0) && (argc < 4)) {
@@ -1707,7 +1707,7 @@ void CXFA_FM2JSContext::Num2Time(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Num2Time");
}
}
-void CXFA_FM2JSContext::Time(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Time(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if (args.GetLength() == 0) {
time_t now;
@@ -1722,7 +1722,7 @@ void CXFA_FM2JSContext::Time(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arg
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Time");
}
}
-void CXFA_FM2JSContext::Time2Num(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Time2Num(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if ((argc > 0) && (argc < 4)) {
@@ -1818,7 +1818,7 @@ void CXFA_FM2JSContext::Time2Num(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Time2Num");
}
}
-void CXFA_FM2JSContext::TimeFmt(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::TimeFmt(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if (argc < 3) {
@@ -2162,7 +2162,7 @@ FX_BOOL CXFA_FM2JSContext::IsIsoDateTimeFormat(const FX_CHAR* pData, int32_t iLe
iRet = TRUE;
return iRet;
}
-FX_BOOL CXFA_FM2JSContext::Local2IsoDate(FXJSE_HOBJECT hThis, FX_BSTR szDate, FX_BSTR szFormat, FX_BSTR szLocale, CFX_ByteString &strIsoDate)
+FX_BOOL CXFA_FM2JSContext::Local2IsoDate(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szDate, const CFX_ByteStringC& szFormat, const CFX_ByteStringC& szLocale, CFX_ByteString &strIsoDate)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
CXFA_Document *pDoc = pContext->GetDocument();
@@ -2194,7 +2194,7 @@ FX_BOOL CXFA_FM2JSContext::Local2IsoDate(FXJSE_HOBJECT hThis, FX_BSTR szDate, FX
strIsoDate.Format("%4d-%02d-%02d", dt.GetYear(), dt.GetMonth(), dt.GetDay());
return TRUE;
}
-FX_BOOL CXFA_FM2JSContext::Local2IsoTime(FXJSE_HOBJECT hThis, FX_BSTR szTime, FX_BSTR szFormat, FX_BSTR szLocale, CFX_ByteString &strIsoTime)
+FX_BOOL CXFA_FM2JSContext::Local2IsoTime(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szTime, const CFX_ByteStringC& szFormat, const CFX_ByteStringC& szLocale, CFX_ByteString &strIsoTime)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
CXFA_Document *pDoc = pContext->GetDocument();
@@ -2228,7 +2228,7 @@ FX_BOOL CXFA_FM2JSContext::Local2IsoTime(FXJSE_HOBJECT hThis, FX_BSTR szTime, FX
strIsoTime.Format("%02d:%02d:%02d.%03d", utime.GetHour(), utime.GetMinute(), utime.GetSecond(), utime.GetMillisecond());
return TRUE;
}
-FX_BOOL CXFA_FM2JSContext::IsoDate2Local(FXJSE_HOBJECT hThis, FX_BSTR szDate, FX_BSTR szFormat, FX_BSTR szLocale, CFX_ByteString &strLocalDate)
+FX_BOOL CXFA_FM2JSContext::IsoDate2Local(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szDate, const CFX_ByteStringC& szFormat, const CFX_ByteStringC& szLocale, CFX_ByteString &strLocalDate)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
CXFA_Document *pDoc = pContext->GetDocument();
@@ -2260,7 +2260,7 @@ FX_BOOL CXFA_FM2JSContext::IsoDate2Local(FXJSE_HOBJECT hThis, FX_BSTR szDate, FX
strLocalDate = FX_UTF8Encode(wsRet, wsRet.GetLength());
return TRUE;
}
-FX_BOOL CXFA_FM2JSContext::IsoTime2Local(FXJSE_HOBJECT hThis, FX_BSTR szTime, FX_BSTR szFormat, FX_BSTR szLocale, CFX_ByteString &strLocalTime)
+FX_BOOL CXFA_FM2JSContext::IsoTime2Local(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szTime, const CFX_ByteStringC& szFormat, const CFX_ByteStringC& szLocale, CFX_ByteString &strLocalTime)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
CXFA_Document *pDoc = pContext->GetDocument();
@@ -2294,7 +2294,7 @@ FX_BOOL CXFA_FM2JSContext::IsoTime2Local(FXJSE_HOBJECT hThis, FX_BSTR szTime, FX
strLocalTime = FX_UTF8Encode(wsRet, wsRet.GetLength());
return TRUE;
}
-FX_BOOL CXFA_FM2JSContext::GetGMTTime(FXJSE_HOBJECT hThis, FX_BSTR szTime, FX_BSTR szFormat, FX_BSTR szLocale, CFX_ByteString &strGMTTime)
+FX_BOOL CXFA_FM2JSContext::GetGMTTime(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szTime, const CFX_ByteStringC& szFormat, const CFX_ByteStringC& szLocale, CFX_ByteString &strGMTTime)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
CXFA_Document *pDoc = pContext->GetDocument();
@@ -2328,7 +2328,7 @@ FX_BOOL CXFA_FM2JSContext::GetGMTTime(FXJSE_HOBJECT hThis, FX_BSTR szTime, FX_BS
strGMTTime = FX_UTF8Encode(wsRet, wsRet.GetLength());
return TRUE;
}
-int32_t CXFA_FM2JSContext::DateString2Num(FX_BSTR szDateString)
+int32_t CXFA_FM2JSContext::DateString2Num(const CFX_ByteStringC& szDateString)
{
FX_BOOL bFlags = FALSE;
int32_t iLength = szDateString.GetLength();
@@ -2449,7 +2449,7 @@ static void XFA_FM_AlternateDateTimeSymbols(CFX_WideString &wsPattern, const CFX
}
}
#undef XFA_N
-void CXFA_FM2JSContext::GetLocalDateFormat(FXJSE_HOBJECT hThis, int32_t iStyle, FX_BSTR szLocalStr, CFX_ByteString &strFormat, FX_BOOL bStandard)
+void CXFA_FM2JSContext::GetLocalDateFormat(FXJSE_HOBJECT hThis, int32_t iStyle, const CFX_ByteStringC& szLocalStr, CFX_ByteString &strFormat, FX_BOOL bStandard)
{
FX_LOCALEDATETIMESUBCATEGORY strStyle;
switch (iStyle) {
@@ -2499,7 +2499,7 @@ void CXFA_FM2JSContext::GetLocalDateFormat(FXJSE_HOBJECT hThis, int32_t iStyle,
}
strFormat = FX_UTF8Encode(strRet, strRet.GetLength());
}
-void CXFA_FM2JSContext::GetLocalTimeFormat(FXJSE_HOBJECT hThis, int32_t iStyle, FX_BSTR szLocalStr, CFX_ByteString &strFormat, FX_BOOL bStandard)
+void CXFA_FM2JSContext::GetLocalTimeFormat(FXJSE_HOBJECT hThis, int32_t iStyle, const CFX_ByteStringC& szLocalStr, CFX_ByteString &strFormat, FX_BOOL bStandard)
{
FX_LOCALEDATETIMESUBCATEGORY strStyle;
switch (iStyle) {
@@ -2550,15 +2550,15 @@ void CXFA_FM2JSContext::GetLocalTimeFormat(FXJSE_HOBJECT hThis, int32_t iStyle,
}
strFormat = FX_UTF8Encode(strRet, strRet.GetLength());
}
-void CXFA_FM2JSContext::GetStandardDateFormat(FXJSE_HOBJECT hThis, int32_t iStyle, FX_BSTR szLocalStr, CFX_ByteString &strFormat)
+void CXFA_FM2JSContext::GetStandardDateFormat(FXJSE_HOBJECT hThis, int32_t iStyle, const CFX_ByteStringC& szLocalStr, CFX_ByteString &strFormat)
{
GetLocalDateFormat(hThis, iStyle, szLocalStr, strFormat, TRUE);
}
-void CXFA_FM2JSContext::GetStandardTimeFormat(FXJSE_HOBJECT hThis, int32_t iStyle, FX_BSTR szLocalStr, CFX_ByteString &strFormat)
+void CXFA_FM2JSContext::GetStandardTimeFormat(FXJSE_HOBJECT hThis, int32_t iStyle, const CFX_ByteStringC& szLocalStr, CFX_ByteString &strFormat)
{
GetLocalTimeFormat(hThis, iStyle, szLocalStr, strFormat, TRUE);
}
-void CXFA_FM2JSContext::Num2AllTime(FXJSE_HOBJECT hThis, int32_t iTime, FX_BSTR szFormat, FX_BSTR szLocale, FX_BOOL bGM, CFX_ByteString &strTime)
+void CXFA_FM2JSContext::Num2AllTime(FXJSE_HOBJECT hThis, int32_t iTime, const CFX_ByteStringC& szFormat, const CFX_ByteStringC& szLocale, FX_BOOL bGM, CFX_ByteString &strTime)
{
int32_t iHour = 0;
int32_t iMin = 0;
@@ -2604,7 +2604,7 @@ void CXFA_FM2JSContext::GetLocalTimeZone(int32_t &iHour, int32_t &iMin, int32_t
iMin = iLocalMin - iGMMin;
iSec = iLocalSec - iGMSec;
}
-void CXFA_FM2JSContext::Apr(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Apr(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
if(args.GetLength() == 3) {
@@ -2661,7 +2661,7 @@ void CXFA_FM2JSContext::Apr(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argu
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Apr");
}
}
-void CXFA_FM2JSContext::CTerm(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::CTerm(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
if(args.GetLength() == 3) {
@@ -2693,7 +2693,7 @@ void CXFA_FM2JSContext::CTerm(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Ar
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"CTerm");
}
}
-void CXFA_FM2JSContext::FV(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::FV(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
if(args.GetLength() == 3) {
@@ -2735,7 +2735,7 @@ void CXFA_FM2JSContext::FV(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argum
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"FV");
}
}
-void CXFA_FM2JSContext::IPmt(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::IPmt(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
if(args.GetLength() == 5) {
@@ -2799,7 +2799,7 @@ void CXFA_FM2JSContext::IPmt(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arg
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"IPmt");
}
}
-void CXFA_FM2JSContext::NPV(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::NPV(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
int32_t argc = args.GetLength();
@@ -2847,7 +2847,7 @@ void CXFA_FM2JSContext::NPV(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argu
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"NPV");
}
}
-void CXFA_FM2JSContext::Pmt(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Pmt(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
if(args.GetLength() == 3) {
@@ -2885,7 +2885,7 @@ void CXFA_FM2JSContext::Pmt(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argu
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Pmt");
}
}
-void CXFA_FM2JSContext::PPmt(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::PPmt(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
if(args.GetLength() == 5) {
@@ -2950,7 +2950,7 @@ void CXFA_FM2JSContext::PPmt(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arg
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"PPmt");
}
}
-void CXFA_FM2JSContext::PV(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::PV(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
if(args.GetLength() == 3) {
@@ -2987,7 +2987,7 @@ void CXFA_FM2JSContext::PV(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argum
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"PV");
}
}
-void CXFA_FM2JSContext::Rate(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Rate(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
if(args.GetLength() == 3) {
@@ -3019,7 +3019,7 @@ void CXFA_FM2JSContext::Rate(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arg
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Rate");
}
}
-void CXFA_FM2JSContext::Term(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Term(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
if(args.GetLength() == 3) {
@@ -3051,7 +3051,7 @@ void CXFA_FM2JSContext::Term(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arg
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Term");
}
}
-void CXFA_FM2JSContext::Choose(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Choose(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -3127,7 +3127,7 @@ void CXFA_FM2JSContext::Choose(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_A
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Choose");
}
}
-void CXFA_FM2JSContext::Exists(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Exists(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if (args.GetLength() == 1) {
FXJSE_HVALUE argOne = args.GetValue(0);
@@ -3138,7 +3138,7 @@ void CXFA_FM2JSContext::Exists(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_A
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Exists");
}
}
-void CXFA_FM2JSContext::HasValue(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::HasValue(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if (args.GetLength() == 1) {
FXJSE_HVALUE argOne = GetSimpleHValue(hThis, args, 0);
@@ -3158,7 +3158,7 @@ void CXFA_FM2JSContext::HasValue(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"HasValue");
}
}
-void CXFA_FM2JSContext::Oneof(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Oneof(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if(argc > 1) {
@@ -3185,7 +3185,7 @@ void CXFA_FM2JSContext::Oneof(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Ar
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Oneof");
}
}
-void CXFA_FM2JSContext::Within(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Within(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if(argc == 3) {
@@ -3218,7 +3218,7 @@ void CXFA_FM2JSContext::Within(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_A
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Within");
}
}
-void CXFA_FM2JSContext::If(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::If(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if (args.GetLength() == 3) {
@@ -3235,7 +3235,7 @@ void CXFA_FM2JSContext::If(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argum
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"If");
}
}
-void CXFA_FM2JSContext::Eval(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Eval(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -3263,7 +3263,7 @@ void CXFA_FM2JSContext::Eval(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arg
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Eval");
}
}
-void CXFA_FM2JSContext::Ref(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Ref(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -3332,7 +3332,7 @@ void CXFA_FM2JSContext::Ref(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argu
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Ref");
}
}
-void CXFA_FM2JSContext::UnitType(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::UnitType(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if (args.GetLength() == 1) {
FXJSE_HVALUE unitspanValue = GetSimpleHValue(hThis, args, 0);
@@ -3433,7 +3433,7 @@ void CXFA_FM2JSContext::UnitType(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"UnitType");
}
}
-void CXFA_FM2JSContext::UnitValue(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::UnitValue(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if ((argc == 1) || (argc == 2)) {
@@ -3581,7 +3581,7 @@ void CXFA_FM2JSContext::UnitValue(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJS
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"UnitValue");
}
}
-void CXFA_FM2JSContext::At(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::At(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -3608,7 +3608,7 @@ void CXFA_FM2JSContext::At(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argum
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"At");
}
}
-void CXFA_FM2JSContext::Concat(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Concat(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -3639,7 +3639,7 @@ void CXFA_FM2JSContext::Concat(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_A
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Concat");
}
}
-void CXFA_FM2JSContext::Decode(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Decode(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -3682,7 +3682,7 @@ void CXFA_FM2JSContext::Decode(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_A
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Decode");
}
}
-void CXFA_FM2JSContext::DecodeURL (FX_BSTR szURLString, CFX_ByteTextBuf &szResultString)
+void CXFA_FM2JSContext::DecodeURL (const CFX_ByteStringC& szURLString, CFX_ByteTextBuf &szResultString)
{
CFX_WideString wsURLString = CFX_WideString::FromUTF8(szURLString.GetCStr(), szURLString.GetLength());
const FX_WCHAR* pData = wsURLString;
@@ -3734,7 +3734,7 @@ void CXFA_FM2JSContext::DecodeURL (FX_BSTR szURLString, CFX_ByteTextBuf &szResu
wsResultBuf.AppendChar(0);
szResultString = FX_UTF8Encode(wsResultBuf.GetBuffer(), wsResultBuf.GetLength());
}
-void CXFA_FM2JSContext::DecodeHTML(FX_BSTR szHTMLString, CFX_ByteTextBuf &szResultString)
+void CXFA_FM2JSContext::DecodeHTML(const CFX_ByteStringC& szHTMLString, CFX_ByteTextBuf &szResultString)
{
CFX_WideString wsHTMLString = CFX_WideString::FromUTF8(szHTMLString.GetCStr(), szHTMLString.GetLength());
FX_WCHAR strString[9];
@@ -3804,7 +3804,7 @@ void CXFA_FM2JSContext::DecodeHTML(FX_BSTR szHTMLString, CFX_ByteTextBuf &szResu
wsResultBuf.AppendChar(0);
szResultString = FX_UTF8Encode(wsResultBuf.GetBuffer(), wsResultBuf.GetLength());
}
-void CXFA_FM2JSContext::DecodeXML (FX_BSTR szXMLString, CFX_ByteTextBuf &szResultString)
+void CXFA_FM2JSContext::DecodeXML (const CFX_ByteStringC& szXMLString, CFX_ByteTextBuf &szResultString)
{
CFX_WideString wsXMLString = CFX_WideString::FromUTF8(szXMLString.GetCStr(), szXMLString.GetLength());
FX_WCHAR strString[9];
@@ -3903,7 +3903,7 @@ void CXFA_FM2JSContext::DecodeXML (FX_BSTR szXMLString, CFX_ByteTextBuf &szResu
wsXMLBuf.AppendChar(0);
szResultString = FX_UTF8Encode(wsXMLBuf.GetBuffer(), wsXMLBuf.GetLength());
}
-void CXFA_FM2JSContext::Encode(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Encode(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -3946,7 +3946,7 @@ void CXFA_FM2JSContext::Encode(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_A
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Encode");
}
}
-void CXFA_FM2JSContext::EncodeURL (FX_BSTR szURLString, CFX_ByteTextBuf &szResultBuf)
+void CXFA_FM2JSContext::EncodeURL (const CFX_ByteStringC& szURLString, CFX_ByteTextBuf &szResultBuf)
{
CFX_WideString wsURLString = CFX_WideString::FromUTF8(szURLString.GetCStr(), szURLString.GetLength());
CFX_WideTextBuf wsResultBuf;
@@ -4050,7 +4050,7 @@ void CXFA_FM2JSContext::EncodeURL (FX_BSTR szURLString, CFX_ByteTextBuf &szResu
wsResultBuf.AppendChar(0);
szResultBuf = FX_UTF8Encode(wsResultBuf.GetBuffer(), wsResultBuf.GetLength());
}
-void CXFA_FM2JSContext::EncodeHTML(FX_BSTR szHTMLString, CFX_ByteTextBuf &szResultBuf)
+void CXFA_FM2JSContext::EncodeHTML(const CFX_ByteStringC& szHTMLString, CFX_ByteTextBuf &szResultBuf)
{
CFX_ByteString str = szHTMLString.GetCStr();
CFX_WideString wsHTMLString = CFX_WideString::FromUTF8(str, str.GetLength());
@@ -4102,7 +4102,7 @@ void CXFA_FM2JSContext::EncodeHTML(FX_BSTR szHTMLString, CFX_ByteTextBuf &szResu
wsResultBuf.AppendChar(0);
szResultBuf = FX_UTF8Encode(wsResultBuf.GetBuffer(), wsResultBuf.GetLength());
}
-void CXFA_FM2JSContext::EncodeXML (FX_BSTR szXMLString, CFX_ByteTextBuf &szResultBuf)
+void CXFA_FM2JSContext::EncodeXML (const CFX_ByteStringC& szXMLString, CFX_ByteTextBuf &szResultBuf)
{
CFX_WideString wsXMLString = CFX_WideString::FromUTF8(szXMLString.GetCStr(), szXMLString.GetLength());
CFX_WideTextBuf wsResultBuf;
@@ -4188,7 +4188,7 @@ void CXFA_FM2JSContext::EncodeXML (FX_BSTR szXMLString, CFX_ByteTextBuf &szResu
wsResultBuf.AppendChar(0);
szResultBuf = FX_UTF8Encode(wsResultBuf.GetBuffer(), wsResultBuf.GetLength());
}
-FX_BOOL CXFA_FM2JSContext::HTMLSTR2Code(FX_WSTR pData, uint32_t &iCode)
+FX_BOOL CXFA_FM2JSContext::HTMLSTR2Code(const CFX_WideStringC& pData, uint32_t &iCode)
{
int32_t iLength = pData.GetLength();
uint32_t uHash = FX_HashCode_String_GetW(pData.GetPtr(), iLength);
@@ -4228,7 +4228,7 @@ FX_BOOL CXFA_FM2JSContext::HTMLCode2STR(uint32_t iCode, CFX_WideString &wsHTMLRe
} while (iStart <= iEnd);
return FALSE;
}
-static FX_BOOL XFA_PATTERN_STRING_Type(FX_BSTR szPattern, FX_DWORD& patternType)
+static FX_BOOL XFA_PATTERN_STRING_Type(const CFX_ByteStringC& szPattern, FX_DWORD& patternType)
{
CFX_WideString wsPattern = CFX_WideString::FromUTF8(szPattern.GetCStr(), szPattern.GetLength());
if (FX_WSTRC(L"datetime") == wsPattern.Left(8)) {
@@ -4305,7 +4305,7 @@ static FX_BOOL XFA_PATTERN_STRING_Type(FX_BSTR szPattern, FX_DWORD& patternType)
}
return FALSE;
}
-void CXFA_FM2JSContext::Format(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Format(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
int32_t argc = args.GetLength();
@@ -4390,7 +4390,7 @@ void CXFA_FM2JSContext::Format(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_A
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Format");
}
}
-void CXFA_FM2JSContext::Left(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Left(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -4418,7 +4418,7 @@ void CXFA_FM2JSContext::Left(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arg
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Left");
}
}
-void CXFA_FM2JSContext::Len(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Len(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -4436,7 +4436,7 @@ void CXFA_FM2JSContext::Len(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argu
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Len");
}
}
-void CXFA_FM2JSContext::Lower(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Lower(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if ((argc > 0) && (argc < 3)) {
@@ -4480,7 +4480,7 @@ void CXFA_FM2JSContext::Lower(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Ar
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Lower");
}
}
-void CXFA_FM2JSContext::Ltrim(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Ltrim(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -4499,7 +4499,7 @@ void CXFA_FM2JSContext::Ltrim(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Ar
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Ltrim");
}
}
-void CXFA_FM2JSContext::Parse(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Parse(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
if (args.GetLength() == 2) {
@@ -4627,7 +4627,7 @@ void CXFA_FM2JSContext::Parse(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Ar
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Parse");
}
}
-void CXFA_FM2JSContext::Replace(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Replace(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if ((argc == 2) || (argc == 3)) {
@@ -4692,7 +4692,7 @@ void CXFA_FM2JSContext::Replace(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Replace");
}
}
-void CXFA_FM2JSContext::Right(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Right(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -4720,7 +4720,7 @@ void CXFA_FM2JSContext::Right(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Ar
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Right");
}
}
-void CXFA_FM2JSContext::Rtrim(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Rtrim(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -4739,7 +4739,7 @@ void CXFA_FM2JSContext::Rtrim(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Ar
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Rtrim");
}
}
-void CXFA_FM2JSContext::Space(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Space(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -4765,7 +4765,7 @@ void CXFA_FM2JSContext::Space(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Ar
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Space");
}
}
-void CXFA_FM2JSContext::Str(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Str(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if ((argc > 0) && (argc < 4)) {
@@ -4888,7 +4888,7 @@ void CXFA_FM2JSContext::Str(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argu
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Str");
}
}
-void CXFA_FM2JSContext::Stuff(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Stuff(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if ((argc == 3) || (argc == 4)) {
@@ -4949,7 +4949,7 @@ void CXFA_FM2JSContext::Stuff(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Ar
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Stuff");
}
}
-void CXFA_FM2JSContext::Substr(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Substr(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if(argc == 3) {
@@ -4990,7 +4990,7 @@ void CXFA_FM2JSContext::Substr(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_A
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Substr");
}
}
-void CXFA_FM2JSContext::Uuid(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Uuid(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if((argc == 0) || (argc == 1)) {
@@ -5013,7 +5013,7 @@ void CXFA_FM2JSContext::Uuid(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arg
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Uuid");
}
}
-void CXFA_FM2JSContext::Upper(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Upper(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if ((argc > 0) && (argc < 3)) {
@@ -5057,7 +5057,7 @@ void CXFA_FM2JSContext::Upper(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Ar
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Upper");
}
}
-void CXFA_FM2JSContext::WordNum(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::WordNum(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t argc = args.GetLength();
if ((argc > 0) && (argc < 4)) {
@@ -5114,7 +5114,7 @@ void CXFA_FM2JSContext::WordNum(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"WordNum");
}
}
-void CXFA_FM2JSContext::TrillionUS(FX_BSTR szData, CFX_ByteTextBuf &strBuf)
+void CXFA_FM2JSContext::TrillionUS(const CFX_ByteStringC& szData, CFX_ByteTextBuf &strBuf)
{
CFX_ByteStringC pUnits[] = { "zero", "one", "two", "three", "four", "five", "six", "seven", "eight", "nine"};
CFX_ByteStringC pCapUnits[] = { "Zero", "One", "Two", "Three", "Four", "Five", "Six", "Seven", "Eight", "Nine"};
@@ -5205,7 +5205,7 @@ void CXFA_FM2JSContext::TrillionUS(FX_BSTR szData, CFX_ByteTextBuf &strBuf)
iIndex += 3;
}
}
-void CXFA_FM2JSContext::WordUS(FX_BSTR szData, int32_t iStyle, CFX_ByteTextBuf &strBuf)
+void CXFA_FM2JSContext::WordUS(const CFX_ByteStringC& szData, int32_t iStyle, CFX_ByteTextBuf &strBuf)
{
const FX_CHAR* pData = szData.GetCStr();
int32_t iLength = szData.GetLength();
@@ -5305,7 +5305,7 @@ void CXFA_FM2JSContext::WordUS(FX_BSTR szData, int32_t iStyle, CFX_ByteTextBuf &
break;
}
}
-void CXFA_FM2JSContext::Get(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Get(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
int32_t argc = args.GetLength();
@@ -5337,7 +5337,7 @@ void CXFA_FM2JSContext::Get(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argu
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Get");
}
}
-void CXFA_FM2JSContext::Post(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Post(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
int32_t argc = args.GetLength();
@@ -5400,7 +5400,7 @@ void CXFA_FM2JSContext::Post(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arg
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Post");
}
}
-void CXFA_FM2JSContext::Put(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::Put(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
int32_t argc = args.GetLength();
@@ -5443,7 +5443,7 @@ void CXFA_FM2JSContext::Put(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Argu
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Put");
}
}
-void CXFA_FM2JSContext::assign_value_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::assign_value_operator(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -5491,7 +5491,7 @@ void CXFA_FM2JSContext::assign_value_operator(FXJSE_HOBJECT hThis, FX_BSTR szFun
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::logical_or_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::logical_or_operator(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if (args.GetLength() == 2) {
FXJSE_HVALUE argFirst = GetSimpleHValue(hThis, args, 0);
@@ -5510,7 +5510,7 @@ void CXFA_FM2JSContext::logical_or_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncN
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::logical_and_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::logical_and_operator(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if (args.GetLength() == 2) {
FXJSE_HVALUE argFirst = GetSimpleHValue(hThis, args, 0);
@@ -5529,7 +5529,7 @@ void CXFA_FM2JSContext::logical_and_operator(FXJSE_HOBJECT hThis, FX_BSTR szFunc
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::equality_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::equality_operator(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if (args.GetLength() == 2) {
if (fm_ref_equal(hThis, args)) {
@@ -5558,7 +5558,7 @@ void CXFA_FM2JSContext::equality_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncNam
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::notequality_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::notequality_operator(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if (args.GetLength() == 2) {
if (fm_ref_equal(hThis, args)) {
@@ -5617,7 +5617,7 @@ FX_BOOL CXFA_FM2JSContext::fm_ref_equal(FXJSE_HOBJECT hThis, CFXJSE_Arguments &a
FXJSE_Value_Release(argSecond);
return bRet;
}
-void CXFA_FM2JSContext::less_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::less_operator(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if (args.GetLength() == 2) {
FXJSE_HVALUE argFirst = GetSimpleHValue(hThis, args, 0);
@@ -5642,7 +5642,7 @@ void CXFA_FM2JSContext::less_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, C
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::lessequal_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::lessequal_operator(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if (args.GetLength() == 2) {
FXJSE_HVALUE argFirst = GetSimpleHValue(hThis, args, 0);
@@ -5667,7 +5667,7 @@ void CXFA_FM2JSContext::lessequal_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncNa
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::greater_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::greater_operator(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if (args.GetLength() == 2) {
FXJSE_HVALUE argFirst = GetSimpleHValue(hThis, args, 0);
@@ -5692,7 +5692,7 @@ void CXFA_FM2JSContext::greater_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::greaterequal_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::greaterequal_operator(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if (args.GetLength() == 2) {
FXJSE_HVALUE argFirst = GetSimpleHValue(hThis, args, 0);
@@ -5717,7 +5717,7 @@ void CXFA_FM2JSContext::greaterequal_operator(FXJSE_HOBJECT hThis, FX_BSTR szFun
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::plus_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::plus_operator(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if (args.GetLength() == 2) {
FXJSE_HVALUE argFirst = args.GetValue(0);
@@ -5736,7 +5736,7 @@ void CXFA_FM2JSContext::plus_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, C
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::minus_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::minus_operator(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if (args.GetLength() == 2) {
FXJSE_HVALUE argFirst = GetSimpleHValue(hThis, args, 0);
@@ -5755,7 +5755,7 @@ void CXFA_FM2JSContext::minus_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName,
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::multiple_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::multiple_operator(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
if (args.GetLength() == 2) {
FXJSE_HVALUE argFirst = GetSimpleHValue(hThis, args, 0);
@@ -5774,7 +5774,7 @@ void CXFA_FM2JSContext::multiple_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncNam
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::divide_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::divide_operator(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
if (args.GetLength() == 2) {
@@ -5797,7 +5797,7 @@ void CXFA_FM2JSContext::divide_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName,
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::positive_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::positive_operator(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t iLength = args.GetLength();
if (iLength == 1) {
@@ -5813,7 +5813,7 @@ void CXFA_FM2JSContext::positive_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncNam
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::negative_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::negative_operator(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t iLength = args.GetLength();
if (iLength == 1) {
@@ -5829,7 +5829,7 @@ void CXFA_FM2JSContext::negative_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncNam
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::logical_not_operator(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::logical_not_operator(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t iLength = args.GetLength();
if (iLength == 1) {
@@ -5846,7 +5846,7 @@ void CXFA_FM2JSContext::logical_not_operator(FXJSE_HOBJECT hThis, FX_BSTR szFunc
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::dot_accessor(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::dot_accessor(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -5979,7 +5979,7 @@ void CXFA_FM2JSContext::dot_accessor(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CF
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::dotdot_accessor(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::dotdot_accessor(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -6107,7 +6107,7 @@ void CXFA_FM2JSContext::dotdot_accessor(FXJSE_HOBJECT hThis, FX_BSTR szFuncName,
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::eval_translation (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::eval_translation (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -6135,7 +6135,7 @@ void CXFA_FM2JSContext::eval_translation (FXJSE_HOBJECT hThis, FX_BSTR szFuncNam
pContext->ThrowScriptErrorMessage(XFA_IDS_INCORRECT_NUMBER_OF_METHOD, L"Eval");
}
}
-void CXFA_FM2JSContext::is_fm_object(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::is_fm_object(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t iLength = args.GetLength();
if (iLength == 1) {
@@ -6146,7 +6146,7 @@ void CXFA_FM2JSContext::is_fm_object(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CF
FXJSE_Value_SetBoolean(args.GetReturnValue(), FALSE);
}
}
-void CXFA_FM2JSContext::is_fm_array(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::is_fm_array(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
int32_t iLength = args.GetLength();
if (iLength == 1) {
@@ -6158,7 +6158,7 @@ void CXFA_FM2JSContext::is_fm_array(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFX
FXJSE_Value_SetBoolean(args.GetReturnValue(), FALSE);
}
}
-void CXFA_FM2JSContext::get_fm_value(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::get_fm_value(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -6189,7 +6189,7 @@ void CXFA_FM2JSContext::get_fm_value(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CF
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::get_fm_jsobj(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::get_fm_jsobj(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -6211,7 +6211,7 @@ void CXFA_FM2JSContext::get_fm_jsobj(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CF
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::fm_var_filter(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::fm_var_filter(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -6264,7 +6264,7 @@ void CXFA_FM2JSContext::fm_var_filter(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, C
pContext->ThrowScriptErrorMessage(XFA_IDS_COMPILER_ERROR);
}
}
-void CXFA_FM2JSContext::concat_fm_object(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_FM2JSContext::concat_fm_object(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
FXJSE_HRUNTIME hruntime = pContext->GetScriptRuntime();
@@ -6513,7 +6513,7 @@ FX_BOOL CXFA_FM2JSContext::SetObjectDefaultValue(FXJSE_HVALUE hObjectValue, FXJS
}
return bSuccess;
}
-void CXFA_FM2JSContext::GenerateSomExpression(FX_BSTR szName, int32_t iIndexFlags, int32_t iIndexValue, FX_BOOL bIsStar, CFX_ByteString& szSomExp)
+void CXFA_FM2JSContext::GenerateSomExpression(const CFX_ByteStringC& szName, int32_t iIndexFlags, int32_t iIndexValue, FX_BOOL bIsStar, CFX_ByteString& szSomExp)
{
if(bIsStar) {
szSomExp = szName + FX_BSTRC("[*]");
@@ -6537,7 +6537,7 @@ void CXFA_FM2JSContext::GenerateSomExpression(FX_BSTR szName, int32_t iIndexFlag
szSomExp += FX_BSTRC("]");
}
}
-FX_BOOL CXFA_FM2JSContext::GetObjectByName(FXJSE_HOBJECT hThis, FXJSE_HVALUE accessorValue, FX_BSTR szAccessorName)
+FX_BOOL CXFA_FM2JSContext::GetObjectByName(FXJSE_HOBJECT hThis, FXJSE_HVALUE accessorValue, const CFX_ByteStringC& szAccessorName)
{
FX_BOOL bFlags = FALSE;
CXFA_FM2JSContext* pContext = (CXFA_FM2JSContext*)FXJSE_Value_ToObject(hThis, NULL);
@@ -6555,7 +6555,7 @@ FX_BOOL CXFA_FM2JSContext::GetObjectByName(FXJSE_HOBJECT hThis, FXJSE_HVALUE acc
}
return bFlags;
}
-int32_t CXFA_FM2JSContext::ResolveObjects(FXJSE_HOBJECT hThis, FXJSE_HVALUE hRefValue, FX_BSTR bsSomExp, XFA_RESOLVENODE_RS &resoveNodeRS, FX_BOOL bdotAccessor , FX_BOOL bHasNoResolveName )
+int32_t CXFA_FM2JSContext::ResolveObjects(FXJSE_HOBJECT hThis, FXJSE_HVALUE hRefValue, const CFX_ByteStringC& bsSomExp, XFA_RESOLVENODE_RS &resoveNodeRS, FX_BOOL bdotAccessor , FX_BOOL bHasNoResolveName )
{
CFX_WideString wsSomExpression = CFX_WideString::FromUTF8(bsSomExp.GetCStr(), bsSomExp.GetLength());
int32_t iRet = -1;
@@ -6671,7 +6671,7 @@ int32_t CXFA_FM2JSContext::HValueToInteger(FXJSE_HOBJECT hThis, FXJSE_HVALUE hVa
}
return iValue;
}
-FX_DOUBLE CXFA_FM2JSContext::StringToDouble(FX_BSTR szStringVal)
+FX_DOUBLE CXFA_FM2JSContext::StringToDouble(const CFX_ByteStringC& szStringVal)
{
return XFA_ByteStringToDouble(szStringVal);
}
diff --git a/xfa/src/fxfa/src/fm2js/xfa_fm2jscontext.h b/xfa/src/fxfa/src/fm2js/xfa_fm2jscontext.h
index b947bfa740..f0ac12045b 100644
--- a/xfa/src/fxfa/src/fm2js/xfa_fm2jscontext.h
+++ b/xfa/src/fxfa/src/fm2js/xfa_fm2jscontext.h
@@ -9,143 +9,143 @@
class CXFA_FM2JSContext
{
public:
- static void Abs (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Avg (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Ceil (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Count (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Floor (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Max (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Min (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Mod (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Round (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Sum (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Date (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Date2Num (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void DateFmt (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void IsoDate2Num (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void IsoTime2Num (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void LocalDateFmt (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void LocalTimeFmt (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Num2Date (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Num2GMTime (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Num2Time (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Time (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Time2Num (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void TimeFmt (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
+ static void Abs (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Avg (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Ceil (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Count (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Floor (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Max (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Min (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Mod (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Round (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Sum (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Date (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Date2Num (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void DateFmt (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void IsoDate2Num (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void IsoTime2Num (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void LocalDateFmt (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void LocalTimeFmt (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Num2Date (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Num2GMTime (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Num2Time (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Time (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Time2Num (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void TimeFmt (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
static FX_BOOL IsIsoDateFormat (const FX_CHAR* pData, int32_t iLength, int32_t &iStyle, int32_t &iYear, int32_t &iMonth, int32_t &iDay);
static FX_BOOL IsIsoTimeFormat (const FX_CHAR* pData, int32_t iLength, int32_t &iHour, int32_t &iMinute, int32_t &iSecond, int32_t &iMilliSecond, int32_t &iZoneHour, int32_t &iZoneMinute);
static FX_BOOL IsIsoDateTimeFormat (const FX_CHAR* pData, int32_t iLength, int32_t &iYear, int32_t &iMonth, int32_t &iDay, int32_t &iHour, int32_t &iMinute, int32_t &iSecond, int32_t &iMillionSecond, int32_t &iZoneHour, int32_t &iZoneMinute);
- static FX_BOOL Local2IsoDate (FXJSE_HOBJECT hThis, FX_BSTR szDate, FX_BSTR szFormat, FX_BSTR szLocale, CFX_ByteString &strIsoDate);
- static FX_BOOL Local2IsoTime (FXJSE_HOBJECT hThis, FX_BSTR szTime, FX_BSTR szFormat, FX_BSTR szLocale, CFX_ByteString &strIsoTime);
- static FX_BOOL IsoDate2Local (FXJSE_HOBJECT hThis, FX_BSTR szDate, FX_BSTR szFormat, FX_BSTR szLocale, CFX_ByteString &strLocalDate);
- static FX_BOOL IsoTime2Local (FXJSE_HOBJECT hThis, FX_BSTR szTime, FX_BSTR szFormat, FX_BSTR szLocale, CFX_ByteString &strLocalTime);
- static FX_BOOL GetGMTTime (FXJSE_HOBJECT hThis, FX_BSTR szTime, FX_BSTR szFormat, FX_BSTR szLocale, CFX_ByteString &strGMTTime);
- static int32_t DateString2Num (FX_BSTR szDateString);
- static void GetLocalDateFormat (FXJSE_HOBJECT hThis, int32_t iStyle, FX_BSTR szLocalStr, CFX_ByteString &strFormat, FX_BOOL bStandard);
- static void GetLocalTimeFormat (FXJSE_HOBJECT hThis, int32_t iStyle, FX_BSTR szLocalStr, CFX_ByteString &strFormat, FX_BOOL bStandard);
- static void GetStandardDateFormat (FXJSE_HOBJECT hThis, int32_t iStyle, FX_BSTR szLocalStr, CFX_ByteString &strFormat);
- static void GetStandardTimeFormat (FXJSE_HOBJECT hThis, int32_t iStyle, FX_BSTR szLocalStr, CFX_ByteString &strFormat);
+ static FX_BOOL Local2IsoDate (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szDate, const CFX_ByteStringC& szFormat, const CFX_ByteStringC& szLocale, CFX_ByteString &strIsoDate);
+ static FX_BOOL Local2IsoTime (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szTime, const CFX_ByteStringC& szFormat, const CFX_ByteStringC& szLocale, CFX_ByteString &strIsoTime);
+ static FX_BOOL IsoDate2Local (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szDate, const CFX_ByteStringC& szFormat, const CFX_ByteStringC& szLocale, CFX_ByteString &strLocalDate);
+ static FX_BOOL IsoTime2Local (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szTime, const CFX_ByteStringC& szFormat, const CFX_ByteStringC& szLocale, CFX_ByteString &strLocalTime);
+ static FX_BOOL GetGMTTime (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szTime, const CFX_ByteStringC& szFormat, const CFX_ByteStringC& szLocale, CFX_ByteString &strGMTTime);
+ static int32_t DateString2Num (const CFX_ByteStringC& szDateString);
+ static void GetLocalDateFormat (FXJSE_HOBJECT hThis, int32_t iStyle, const CFX_ByteStringC& szLocalStr, CFX_ByteString &strFormat, FX_BOOL bStandard);
+ static void GetLocalTimeFormat (FXJSE_HOBJECT hThis, int32_t iStyle, const CFX_ByteStringC& szLocalStr, CFX_ByteString &strFormat, FX_BOOL bStandard);
+ static void GetStandardDateFormat (FXJSE_HOBJECT hThis, int32_t iStyle, const CFX_ByteStringC& szLocalStr, CFX_ByteString &strFormat);
+ static void GetStandardTimeFormat (FXJSE_HOBJECT hThis, int32_t iStyle, const CFX_ByteStringC& szLocalStr, CFX_ByteString &strFormat);
- static void Num2AllTime (FXJSE_HOBJECT hThis, int32_t iTime, FX_BSTR szFormat, FX_BSTR szLocale, FX_BOOL bGM, CFX_ByteString &strTime);
+ static void Num2AllTime (FXJSE_HOBJECT hThis, int32_t iTime, const CFX_ByteStringC& szFormat, const CFX_ByteStringC& szLocale, FX_BOOL bGM, CFX_ByteString &strTime);
static void GetLocalTimeZone (int32_t &iHour, int32_t &iMin, int32_t &iSec);
- static void Apr (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void CTerm (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void FV (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void IPmt (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void NPV (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Pmt (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void PPmt (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void PV (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Rate (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Term (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Choose (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Exists (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void HasValue (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Oneof (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Within (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void If (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Eval (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Ref (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void UnitType (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void UnitValue (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
+ static void Apr (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void CTerm (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void FV (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void IPmt (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void NPV (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Pmt (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void PPmt (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void PV (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Rate (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Term (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Choose (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Exists (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void HasValue (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Oneof (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Within (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void If (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Eval (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Ref (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void UnitType (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void UnitValue (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
- static void At (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Concat (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Decode (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void DecodeURL (FX_BSTR szURLString, CFX_ByteTextBuf &szResultBuf);
- static void DecodeHTML (FX_BSTR szHTMLString, CFX_ByteTextBuf &szResultBuf);
- static void DecodeXML (FX_BSTR szXMLString, CFX_ByteTextBuf &szResultBuf);
- static void Encode (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void EncodeURL (FX_BSTR szURLString, CFX_ByteTextBuf &szResultBuf);
- static void EncodeHTML (FX_BSTR szHTMLString, CFX_ByteTextBuf &szResultBuf);
- static void EncodeXML (FX_BSTR szXMLString, CFX_ByteTextBuf &szResultBuf);
- static FX_BOOL HTMLSTR2Code (FX_WSTR pData, uint32_t &iCode);
+ static void At (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Concat (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Decode (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void DecodeURL (const CFX_ByteStringC& szURLString, CFX_ByteTextBuf &szResultBuf);
+ static void DecodeHTML (const CFX_ByteStringC& szHTMLString, CFX_ByteTextBuf &szResultBuf);
+ static void DecodeXML (const CFX_ByteStringC& szXMLString, CFX_ByteTextBuf &szResultBuf);
+ static void Encode (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void EncodeURL (const CFX_ByteStringC& szURLString, CFX_ByteTextBuf &szResultBuf);
+ static void EncodeHTML (const CFX_ByteStringC& szHTMLString, CFX_ByteTextBuf &szResultBuf);
+ static void EncodeXML (const CFX_ByteStringC& szXMLString, CFX_ByteTextBuf &szResultBuf);
+ static FX_BOOL HTMLSTR2Code (const CFX_WideStringC& pData, uint32_t &iCode);
static FX_BOOL HTMLCode2STR (uint32_t iCode, CFX_WideString &wsHTMLReserve);
- static void Format (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Left (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Len (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Lower (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Ltrim (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Parse (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Replace (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Right (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Rtrim (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Space (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Str (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Stuff (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Substr (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Uuid (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Upper (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void WordNum (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void TrillionUS (FX_BSTR szData, CFX_ByteTextBuf &strBuf);
- static void WordUS (FX_BSTR szData, int32_t iStyle, CFX_ByteTextBuf &strBuf);
+ static void Format (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Left (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Len (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Lower (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Ltrim (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Parse (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Replace (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Right (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Rtrim (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Space (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Str (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Stuff (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Substr (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Uuid (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Upper (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void WordNum (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void TrillionUS (const CFX_ByteStringC& szData, CFX_ByteTextBuf &strBuf);
+ static void WordUS (const CFX_ByteStringC& szData, int32_t iStyle, CFX_ByteTextBuf &strBuf);
- static void Get (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Post (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void Put (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void assign_value_operator (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void logical_or_operator (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void logical_and_operator (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void equality_operator (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void notequality_operator (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
+ static void Get (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Post (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void Put (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void assign_value_operator (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void logical_or_operator (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void logical_and_operator (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void equality_operator (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void notequality_operator (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
static FX_BOOL fm_ref_equal (FXJSE_HOBJECT hThis, CFXJSE_Arguments &args);
- static void less_operator (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void lessequal_operator (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void greater_operator (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void greaterequal_operator (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void plus_operator (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void minus_operator (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void multiple_operator (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void divide_operator (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void positive_operator (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void negative_operator (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void logical_not_operator (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void dot_accessor (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void dotdot_accessor (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void eval_translation (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void is_fm_object (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void is_fm_array (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void get_fm_value (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void get_fm_jsobj (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void fm_var_filter (FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static void concat_fm_object(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
+ static void less_operator (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void lessequal_operator (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void greater_operator (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void greaterequal_operator (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void plus_operator (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void minus_operator (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void multiple_operator (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void divide_operator (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void positive_operator (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void negative_operator (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void logical_not_operator (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void dot_accessor (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void dotdot_accessor (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void eval_translation (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void is_fm_object (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void is_fm_array (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void get_fm_value (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void get_fm_jsobj (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void fm_var_filter (FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static void concat_fm_object(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
static int32_t hvalue_get_array_length (FXJSE_HOBJECT hThis, FXJSE_HVALUE arg);
static FX_BOOL simpleValueCompare (FXJSE_HOBJECT hThis, FXJSE_HVALUE firstValue, FXJSE_HVALUE secondValue);
static void unfoldArgs (FXJSE_HOBJECT hThis, CFXJSE_Arguments &args, FXJSE_HVALUE *&resultValues, int32_t &iCount, int32_t iStart = 0);
static void GetObjectDefaultValue(FXJSE_HVALUE hObjectValue, FXJSE_HVALUE hDefaultValue);
static FX_BOOL SetObjectDefaultValue(FXJSE_HVALUE hObjectValue, FXJSE_HVALUE hNewValue);
- static void GenerateSomExpression(FX_BSTR szName, int32_t iIndexFlags, int32_t iIndexValue, FX_BOOL bIsStar, CFX_ByteString& szSomExp);
- static FX_BOOL GetObjectByName(FXJSE_HOBJECT hThis, FXJSE_HVALUE accessorValue, FX_BSTR szAccessorName);
- static int32_t ResolveObjects(FXJSE_HOBJECT hThis, FXJSE_HVALUE hParentValue, FX_BSTR bsSomExp, XFA_RESOLVENODE_RS &resoveNodeRS, FX_BOOL bdotAccessor = TRUE, FX_BOOL bHasNoResolveName = FALSE);
+ static void GenerateSomExpression(const CFX_ByteStringC& szName, int32_t iIndexFlags, int32_t iIndexValue, FX_BOOL bIsStar, CFX_ByteString& szSomExp);
+ static FX_BOOL GetObjectByName(FXJSE_HOBJECT hThis, FXJSE_HVALUE accessorValue, const CFX_ByteStringC& szAccessorName);
+ static int32_t ResolveObjects(FXJSE_HOBJECT hThis, FXJSE_HVALUE hParentValue, const CFX_ByteStringC& bsSomExp, XFA_RESOLVENODE_RS &resoveNodeRS, FX_BOOL bdotAccessor = TRUE, FX_BOOL bHasNoResolveName = FALSE);
static void ParseResolveResult(FXJSE_HOBJECT hThis, const XFA_RESOLVENODE_RS& resoveNodeRS, FXJSE_HVALUE hParentValue, FXJSE_HVALUE *&resultValues, int32_t &iSize, FX_BOOL &bAttribute);
static FXJSE_HVALUE GetSimpleHValue (FXJSE_HOBJECT hThis, CFXJSE_Arguments &args, uint32_t index);
static FX_BOOL HValueIsNull (FXJSE_HOBJECT hThis, FXJSE_HVALUE hValue);
static int32_t HValueToInteger (FXJSE_HOBJECT hThis, FXJSE_HVALUE hValue);
- static FX_DOUBLE StringToDouble(FX_BSTR szStringVal);
+ static FX_DOUBLE StringToDouble(const CFX_ByteStringC& szStringVal);
static FX_FLOAT HValueToFloat (FXJSE_HOBJECT hThis, FXJSE_HVALUE hValue);
static FX_DOUBLE HValueToDouble (FXJSE_HOBJECT hThis, FXJSE_HVALUE hValue);
static void HValueToUTF8String (FXJSE_HVALUE hValue, CFX_ByteString& outputValue);
diff --git a/xfa/src/fxfa/src/fm2js/xfa_fmparse.cpp b/xfa/src/fxfa/src/fm2js/xfa_fmparse.cpp
index 590fa3fd76..768c080123 100644
--- a/xfa/src/fxfa/src/fm2js/xfa_fmparse.cpp
+++ b/xfa/src/fxfa/src/fm2js/xfa_fmparse.cpp
@@ -23,7 +23,7 @@ CXFA_FMParse::~CXFA_FMParse()
m_pScript = 0;
m_pToken = 0;
}
-int32_t CXFA_FMParse::Init(FX_WSTR wsFormcalc, CXFA_FMErrorInfo *pErrorInfo)
+int32_t CXFA_FMParse::Init(const CFX_WideStringC& wsFormcalc, CXFA_FMErrorInfo *pErrorInfo)
{
m_pScript = wsFormcalc.GetPtr();
m_uLength = wsFormcalc.GetLength();
diff --git a/xfa/src/fxfa/src/fm2js/xfa_fmparse.h b/xfa/src/fxfa/src/fm2js/xfa_fmparse.h
index e610ab56ef..64bd835010 100644
--- a/xfa/src/fxfa/src/fm2js/xfa_fmparse.h
+++ b/xfa/src/fxfa/src/fm2js/xfa_fmparse.h
@@ -11,7 +11,7 @@ class CXFA_FMParse
public:
CXFA_FMParse();
~CXFA_FMParse();
- int32_t Init(FX_WSTR wsFormcalc, CXFA_FMErrorInfo *pErrorInfo);
+ int32_t Init(const CFX_WideStringC& wsFormcalc, CXFA_FMErrorInfo *pErrorInfo);
void NextToken();
void Check(XFA_FM_TOKEN op);
void Error(FX_DWORD lineNum, XFA_FM_ERRMSG msg, ...);
diff --git a/xfa/src/fxfa/src/fm2js/xfa_lexer.cpp b/xfa/src/fxfa/src/fm2js/xfa_lexer.cpp
index 4c24f78b1d..ba6221979d 100644
--- a/xfa/src/fxfa/src/fm2js/xfa_lexer.cpp
+++ b/xfa/src/fxfa/src/fm2js/xfa_lexer.cpp
@@ -166,7 +166,7 @@ CXFA_FMToken::CXFA_FMToken( FX_DWORD uLineNum )
CXFA_FMToken::~CXFA_FMToken()
{
}
-CXFA_FMLexer::CXFA_FMLexer(FX_WSTR wsFormCalc, CXFA_FMErrorInfo *pErrorInfo)
+CXFA_FMLexer::CXFA_FMLexer(const CFX_WideStringC& wsFormCalc, CXFA_FMErrorInfo *pErrorInfo)
{
m_pScript = wsFormCalc.GetPtr();
m_uLength = wsFormCalc.GetLength();
@@ -534,7 +534,7 @@ void CXFA_FMLexer::Comment( const FX_WCHAR* p, const FX_WCHAR* &pEnd )
}
pEnd = p;
}
-XFA_FM_TOKEN CXFA_FMLexer::IsKeyword(FX_WSTR str)
+XFA_FM_TOKEN CXFA_FMLexer::IsKeyword(const CFX_WideStringC& str)
{
int32_t iLength = str.GetLength();
uint32_t uHash = FX_HashCode_String_GetW(str.GetPtr(), iLength, TRUE);
diff --git a/xfa/src/fxfa/src/fm2js/xfa_lexer.h b/xfa/src/fxfa/src/fm2js/xfa_lexer.h
index 2850ce5f75..a3ab6253a6 100644
--- a/xfa/src/fxfa/src/fm2js/xfa_lexer.h
+++ b/xfa/src/fxfa/src/fm2js/xfa_lexer.h
@@ -41,14 +41,14 @@ public:
class CXFA_FMLexer
{
public:
- CXFA_FMLexer(FX_WSTR wsFormcalc, CXFA_FMErrorInfo *pErrorInfo);
+ CXFA_FMLexer(const CFX_WideStringC& wsFormcalc, CXFA_FMErrorInfo *pErrorInfo);
~CXFA_FMLexer();
CXFA_FMToken* NextToken();
FX_DWORD Number(CXFA_FMToken *t, const FX_WCHAR* p, const FX_WCHAR* &pEnd);
FX_DWORD String(CXFA_FMToken *t, const FX_WCHAR* p, const FX_WCHAR* &pEnd);
FX_DWORD Identifiers(CXFA_FMToken *t, const FX_WCHAR* p, const FX_WCHAR* &pEnd);
void Comment(const FX_WCHAR* p, const FX_WCHAR* &pEnd);
- XFA_FM_TOKEN IsKeyword(FX_WSTR p);
+ XFA_FM_TOKEN IsKeyword(const CFX_WideStringC& p);
void SetCurrentLine(FX_DWORD line)
{
m_uCurrentLine = line;
diff --git a/xfa/src/fxfa/src/fm2js/xfa_program.cpp b/xfa/src/fxfa/src/fm2js/xfa_program.cpp
index 51faea0e91..06d8e10e49 100644
--- a/xfa/src/fxfa/src/fm2js/xfa_program.cpp
+++ b/xfa/src/fxfa/src/fm2js/xfa_program.cpp
@@ -16,7 +16,7 @@ CXFA_FMProgram::~CXFA_FMProgram()
m_globalFunction = 0;
}
}
-int32_t CXFA_FMProgram::Init(FX_WSTR wsFormcalc)
+int32_t CXFA_FMProgram::Init(const CFX_WideStringC& wsFormcalc)
{
return m_parse.Init(wsFormcalc, &m_pErrorInfo);
}
diff --git a/xfa/src/fxfa/src/fm2js/xfa_program.h b/xfa/src/fxfa/src/fm2js/xfa_program.h
index a7453d4d1d..2e8149e543 100644
--- a/xfa/src/fxfa/src/fm2js/xfa_program.h
+++ b/xfa/src/fxfa/src/fm2js/xfa_program.h
@@ -11,7 +11,7 @@ class CXFA_FMProgram
public:
CXFA_FMProgram();
~CXFA_FMProgram();
- int32_t Init(FX_WSTR wsFormcalc);
+ int32_t Init(const CFX_WideStringC& wsFormcalc);
int32_t ParseProgram();
int32_t TranslateProgram(CFX_WideTextBuf &wsJavaScript);
CXFA_FMErrorInfo& GetError()
diff --git a/xfa/src/fxfa/src/fm2js/xfa_simpleexpression.cpp b/xfa/src/fxfa/src/fm2js/xfa_simpleexpression.cpp
index d52ab7c076..cd39caaffc 100644
--- a/xfa/src/fxfa/src/fm2js/xfa_simpleexpression.cpp
+++ b/xfa/src/fxfa/src/fm2js/xfa_simpleexpression.cpp
@@ -524,7 +524,7 @@ FX_BOOL CXFA_FMCallExpression::IsBuildInFunc(CFX_WideTextBuf& funcName)
} while (iStart <= iEnd);
return FALSE;
}
-FX_DWORD CXFA_FMCallExpression::IsSomMethodWithObjPara(FX_WSTR methodName)
+FX_DWORD CXFA_FMCallExpression::IsSomMethodWithObjPara(const CFX_WideStringC& methodName)
{
int32_t iLength = methodName.GetLength();
uint32_t uHash = FX_HashCode_String_GetW(methodName.GetPtr(), iLength);
diff --git a/xfa/src/fxfa/src/fm2js/xfa_simpleexpression.h b/xfa/src/fxfa/src/fm2js/xfa_simpleexpression.h
index bacd1d3c38..a66461d28a 100644
--- a/xfa/src/fxfa/src/fm2js/xfa_simpleexpression.h
+++ b/xfa/src/fxfa/src/fm2js/xfa_simpleexpression.h
@@ -192,7 +192,7 @@ public:
CXFA_FMCallExpression(FX_DWORD line, CXFA_FMSimpleExpression *pExp, CFX_PtrArray *pArguments, FX_BOOL bIsSomMethod);
virtual ~CXFA_FMCallExpression();
virtual FX_BOOL IsBuildInFunc(CFX_WideTextBuf& funcName);
- virtual FX_DWORD IsSomMethodWithObjPara(FX_WSTR methodName);
+ virtual FX_DWORD IsSomMethodWithObjPara(const CFX_WideStringC& methodName);
virtual void ToJavaScript(CFX_WideTextBuf& javascript);
private:
FX_BOOL m_bIsSomMethod;
diff --git a/xfa/src/fxfa/src/parser/xfa_basic_imp.cpp b/xfa/src/fxfa/src/parser/xfa_basic_imp.cpp
index 151147b4dc..5195a362c0 100644
--- a/xfa/src/fxfa/src/parser/xfa_basic_imp.cpp
+++ b/xfa/src/fxfa/src/parser/xfa_basic_imp.cpp
@@ -38,7 +38,7 @@ extern const XFA_METHODINFO g_SomMethodData[];
extern const int32_t g_iSomMethodCount;
extern const XFA_SCRIPTATTRIBUTEINFO g_SomAttributeData[];
extern const int32_t g_iSomAttributeCount;
-XFA_LPCPACKETINFO XFA_GetPacketByName(FX_WSTR wsName)
+XFA_LPCPACKETINFO XFA_GetPacketByName(const CFX_WideStringC& wsName)
{
int32_t iLength = wsName.GetLength();
if (iLength == 0) {
@@ -75,7 +75,7 @@ XFA_LPCPACKETINFO XFA_GetPacketByID(FX_DWORD dwPacket)
} while (iStart <= iEnd);
return NULL;
}
-XFA_LPCATTRIBUTEENUMINFO XFA_GetAttributeEnumByName(FX_WSTR wsName)
+XFA_LPCATTRIBUTEENUMINFO XFA_GetAttributeEnumByName(const CFX_WideStringC& wsName)
{
int32_t iLength = wsName.GetLength();
if (iLength == 0) {
@@ -104,7 +104,7 @@ int32_t XFA_GetAttributeCount()
{
return g_iXFAAttributeCount;
}
-XFA_LPCATTRIBUTEINFO XFA_GetAttributeByName(FX_WSTR wsName)
+XFA_LPCATTRIBUTEINFO XFA_GetAttributeByName(const CFX_WideStringC& wsName)
{
int32_t iLength = wsName.GetLength();
if (iLength == 0) {
@@ -194,7 +194,7 @@ int32_t XFA_GetElementCount()
{
return g_iXFAElementCount;
}
-XFA_LPCELEMENTINFO XFA_GetElementByName(FX_WSTR wsName)
+XFA_LPCELEMENTINFO XFA_GetElementByName(const CFX_WideStringC& wsName)
{
int32_t iLength = wsName.GetLength();
if (iLength == 0) {
@@ -374,7 +374,7 @@ int32_t XFA_GetMethodCount()
{
return g_iSomMethodCount;
}
-XFA_LPCMETHODINFO XFA_GetMethodByName(XFA_ELEMENT eElement, FX_WSTR wsMethodName)
+XFA_LPCMETHODINFO XFA_GetMethodByName(XFA_ELEMENT eElement, const CFX_WideStringC& wsMethodName)
{
int32_t iLength = wsMethodName.GetLength();
if (iLength == 0) {
@@ -405,7 +405,7 @@ XFA_LPCMETHODINFO XFA_GetMethodByName(XFA_ELEMENT eElement, FX_WSTR wsMethodName
}
return NULL;
}
-XFA_LPCSCRIPTATTRIBUTEINFO XFA_GetScriptAttributeByName(XFA_ELEMENT eElement, FX_WSTR wsAttributeName)
+XFA_LPCSCRIPTATTRIBUTEINFO XFA_GetScriptAttributeByName(XFA_ELEMENT eElement, const CFX_WideStringC& wsAttributeName)
{
int32_t iLength = wsAttributeName.GetLength();
if (iLength == 0) {
@@ -436,7 +436,7 @@ XFA_LPCSCRIPTATTRIBUTEINFO XFA_GetScriptAttributeByName(XFA_ELEMENT eElement, FX
}
return NULL;
}
-void CXFA_Measurement::Set(FX_WSTR wsMeasure)
+void CXFA_Measurement::Set(const CFX_WideStringC& wsMeasure)
{
if (wsMeasure.IsEmpty()) {
m_fValue = 0;
@@ -534,7 +534,7 @@ FX_BOOL CXFA_Measurement::ToUnit(XFA_UNIT eUnit, FX_FLOAT &fValue) const
}
return FALSE;
}
-XFA_UNIT CXFA_Measurement::GetUnit(FX_WSTR wsUnit)
+XFA_UNIT CXFA_Measurement::GetUnit(const CFX_WideStringC& wsUnit)
{
if (wsUnit == FX_WSTRC(L"mm")) {
return XFA_UNIT_Mm;
diff --git a/xfa/src/fxfa/src/parser/xfa_document_datadescription_imp.cpp b/xfa/src/fxfa/src/parser/xfa_document_datadescription_imp.cpp
index a559d5415f..db44f53ac7 100644
--- a/xfa/src/fxfa/src/parser/xfa_document_datadescription_imp.cpp
+++ b/xfa/src/fxfa/src/parser/xfa_document_datadescription_imp.cpp
@@ -66,7 +66,7 @@ void XFA_DataDescription_UpdateDataRelation(CXFA_Node* pDataNode, CXFA_Node* pDa
}
}
}
-CXFA_Node* XFA_DataDescription_MaybeCreateDataNode(CXFA_Document* pDocument, CXFA_Node* pDataParent, XFA_ELEMENT eNodeType, FX_WSTR wsName)
+CXFA_Node* XFA_DataDescription_MaybeCreateDataNode(CXFA_Document* pDocument, CXFA_Node* pDataParent, XFA_ELEMENT eNodeType, const CFX_WideStringC& wsName)
{
if(!pDataParent) {
return NULL;
diff --git a/xfa/src/fxfa/src/parser/xfa_document_datadescription_imp.h b/xfa/src/fxfa/src/parser/xfa_document_datadescription_imp.h
index ede14c03aa..5ae9fcc792 100644
--- a/xfa/src/fxfa/src/parser/xfa_document_datadescription_imp.h
+++ b/xfa/src/fxfa/src/parser/xfa_document_datadescription_imp.h
@@ -7,5 +7,5 @@
#ifndef _XFA_DOCUMENT_DATADESCRIPTION_IMP_H_
#define _XFA_DOCUMENT_DATADESCRIPTION_IMP_H_
void XFA_DataDescription_UpdateDataRelation(CXFA_Node* pDataNode, CXFA_Node* pDataDescriptionNode);
-CXFA_Node* XFA_DataDescription_MaybeCreateDataNode(CXFA_Document* pDocument, CXFA_Node* pDataParent, XFA_ELEMENT eNodeType, FX_WSTR wsName);
+CXFA_Node* XFA_DataDescription_MaybeCreateDataNode(CXFA_Document* pDocument, CXFA_Node* pDataParent, XFA_ELEMENT eNodeType, const CFX_WideStringC& wsName);
#endif
diff --git a/xfa/src/fxfa/src/parser/xfa_document_imp.cpp b/xfa/src/fxfa/src/parser/xfa_document_imp.cpp
index 690ed2960e..4f60433dc5 100644
--- a/xfa/src/fxfa/src/parser/xfa_document_imp.cpp
+++ b/xfa/src/fxfa/src/parser/xfa_document_imp.cpp
@@ -99,7 +99,7 @@ IXFA_Notify* CXFA_Document::GetNotify() const
{
return m_pParser->GetNotify();
}
-CXFA_Object* CXFA_Document::GetXFANode(FX_WSTR wsNodeName)
+CXFA_Object* CXFA_Document::GetXFANode(const CFX_WideStringC& wsNodeName)
{
return GetXFANode(FX_HashCode_String_GetW(wsNodeName.GetPtr(), wsNodeName.GetLength()));
}
@@ -291,7 +291,7 @@ XFA_VERSION CXFA_Document::RecognizeXFAVersionNumber(CFX_WideString& wsTemplateN
m_eCurVersionMode = eVersion;
return eVersion;
}
-CXFA_Node* CXFA_Document::GetNodeByID(CXFA_Node* pRoot, FX_WSTR wsID)
+CXFA_Node* CXFA_Document::GetNodeByID(CXFA_Node* pRoot, const CFX_WideStringC& wsID)
{
if(!pRoot || wsID.IsEmpty()) {
return NULL;
diff --git a/xfa/src/fxfa/src/parser/xfa_document_serialize.cpp b/xfa/src/fxfa/src/parser/xfa_document_serialize.cpp
index c8412873d2..69c835ff95 100644
--- a/xfa/src/fxfa/src/parser/xfa_document_serialize.cpp
+++ b/xfa/src/fxfa/src/parser/xfa_document_serialize.cpp
@@ -98,7 +98,7 @@ CFX_WideString XFA_ExportEncodeAttribute(const CFX_WideString& str)
}
return textBuf.GetWideString();
}
-CFX_WideString XFA_ExportEncodeContent(FX_WSTR str)
+CFX_WideString XFA_ExportEncodeContent(const CFX_WideStringC& str)
{
CFX_WideTextBuf textBuf;
int32_t iLen = str.GetLength();
@@ -129,7 +129,7 @@ CFX_WideString XFA_ExportEncodeContent(FX_WSTR str)
}
return textBuf.GetWideString();
}
-static void XFA_SaveAttribute(CXFA_Node* pNode, XFA_ATTRIBUTE eName, FX_WSTR wsName, FX_BOOL bProto, CFX_WideString &wsOutput)
+static void XFA_SaveAttribute(CXFA_Node* pNode, XFA_ATTRIBUTE eName, const CFX_WideStringC& wsName, FX_BOOL bProto, CFX_WideString &wsOutput)
{
CFX_WideString wsValue;
if ((!bProto && !pNode->HasAttribute((XFA_ATTRIBUTE)eName, bProto)) || !pNode->GetAttribute((XFA_ATTRIBUTE)eName, wsValue, FALSE)) {
diff --git a/xfa/src/fxfa/src/parser/xfa_locale.cpp b/xfa/src/fxfa/src/parser/xfa_locale.cpp
index 56a55cd4c3..08b88c1fb1 100644
--- a/xfa/src/fxfa/src/parser/xfa_locale.cpp
+++ b/xfa/src/fxfa/src/parser/xfa_locale.cpp
@@ -114,7 +114,7 @@ void CXFA_XMLLocale::GetEraName(CFX_WideString& wsEraName, FX_BOOL bAD ) const
{
wsEraName = GetCalendarSymbol(FX_BSTRC("era"), bAD ? 1 : 0, FALSE);
}
-CFX_WideString CXFA_XMLLocale::GetCalendarSymbol(FX_BSTR symbol, int index, FX_BOOL bAbbr) const
+CFX_WideString CXFA_XMLLocale::GetCalendarSymbol(const CFX_ByteStringC& symbol, int index, FX_BOOL bAbbr) const
{
CFX_ByteString pstrSymbolNames = symbol + "Names";
CFX_WideString wsSymbolName = L"";
@@ -206,7 +206,7 @@ void CXFA_XMLLocale::GetNumPattern(FX_LOCALENUMSUBCATEGORY eType, CFX_WideString
break;
}
}
-void CXFA_XMLLocale::GetPattern(CXML_Element* pElement, FX_BSTR bsTag, FX_WSTR wsName, CFX_WideString& wsPattern) const
+void CXFA_XMLLocale::GetPattern(CXML_Element* pElement, const CFX_ByteStringC& bsTag, const CFX_WideStringC& wsName, CFX_WideString& wsPattern) const
{
int32_t iCount = pElement->CountElements(FX_BSTRC(""), bsTag);
for (int32_t i = 0; i < iCount; i++) {
@@ -337,7 +337,7 @@ void CXFA_NodeLocale::GetNumPattern(FX_LOCALENUMSUBCATEGORY eType, CFX_WideStrin
break;
}
}
-CXFA_Node* CXFA_NodeLocale::GetNodeByName(CXFA_Node *pParent, FX_WSTR wsName) const
+CXFA_Node* CXFA_NodeLocale::GetNodeByName(CXFA_Node *pParent, const CFX_WideStringC& wsName) const
{
CXFA_Node *pChild = pParent ? pParent->GetNodeItem(XFA_NODEITEM_FirstChild) : NULL;
while (pChild) {
@@ -351,7 +351,7 @@ CXFA_Node* CXFA_NodeLocale::GetNodeByName(CXFA_Node *pParent, FX_WSTR wsName) co
}
return NULL;
}
-CFX_WideString CXFA_NodeLocale::GetSymbol(XFA_ELEMENT eElement, FX_WSTR symbol_type) const
+CFX_WideString CXFA_NodeLocale::GetSymbol(XFA_ELEMENT eElement, const CFX_WideStringC& symbol_type) const
{
CXFA_Node *pSymbols = m_pLocale ? m_pLocale->GetChild(0, eElement) : NULL;
CXFA_Node *pSymbol = GetNodeByName(pSymbols, symbol_type);
diff --git a/xfa/src/fxfa/src/parser/xfa_locale.h b/xfa/src/fxfa/src/parser/xfa_locale.h
index 2df6201c56..329ebc2fdc 100644
--- a/xfa/src/fxfa/src/parser/xfa_locale.h
+++ b/xfa/src/fxfa/src/parser/xfa_locale.h
@@ -27,8 +27,8 @@ public:
protected:
~CXFA_XMLLocale();
- void GetPattern(CXML_Element* pElement, FX_BSTR bsTag, FX_WSTR wsName, CFX_WideString& wsPattern) const;
- CFX_WideString GetCalendarSymbol(FX_BSTR symbol, int index, FX_BOOL bAbbr) const;
+ void GetPattern(CXML_Element* pElement, const CFX_ByteStringC& bsTag, const CFX_WideStringC& wsName, CFX_WideString& wsPattern) const;
+ CFX_WideString GetCalendarSymbol(const CFX_ByteStringC& symbol, int index, FX_BOOL bAbbr) const;
private:
CXML_Element* m_pLocaleData;
};
@@ -52,8 +52,8 @@ public:
virtual void GetNumPattern(FX_LOCALENUMSUBCATEGORY eType, CFX_WideString& wsPattern) const;
protected:
~CXFA_NodeLocale();
- CXFA_Node* GetNodeByName(CXFA_Node *pParent, FX_WSTR wsName) const;
- CFX_WideString GetSymbol(XFA_ELEMENT eElement, FX_WSTR symbol_type) const;
+ CXFA_Node* GetNodeByName(CXFA_Node *pParent, const CFX_WideStringC& wsName) const;
+ CFX_WideString GetSymbol(XFA_ELEMENT eElement, const CFX_WideStringC& symbol_type) const;
CFX_WideString GetCalendarSymbol(XFA_ELEMENT eElement, int index, FX_BOOL bAbbr) const;
CXFA_Node* m_pLocale;
diff --git a/xfa/src/fxfa/src/parser/xfa_localemgr.cpp b/xfa/src/fxfa/src/parser/xfa_localemgr.cpp
index 69b34993b9..ae5eab9d9c 100644
--- a/xfa/src/fxfa/src/parser/xfa_localemgr.cpp
+++ b/xfa/src/fxfa/src/parser/xfa_localemgr.cpp
@@ -838,7 +838,7 @@ IFX_Locale* CXFA_LocaleMgr::GetLocale(FX_WORD lcid)
}
return pLocal;
}
-IFX_Locale* CXFA_LocaleMgr::GetLocaleByName(FX_WSTR wsLocaleName)
+IFX_Locale* CXFA_LocaleMgr::GetLocaleByName(const CFX_WideStringC& wsLocaleName)
{
int32_t iCount = m_LocaleArray.GetSize();
int32_t i = 0;
diff --git a/xfa/src/fxfa/src/parser/xfa_object_imp.cpp b/xfa/src/fxfa/src/parser/xfa_object_imp.cpp
index c1d09fdbdc..c6db2235ba 100644
--- a/xfa/src/fxfa/src/parser/xfa_object_imp.cpp
+++ b/xfa/src/fxfa/src/parser/xfa_object_imp.cpp
@@ -1677,7 +1677,7 @@ static const XFA_ExecEventParaInfo gs_eventParaInfos[] = {
{0xfc82d695, L"postSave", XFA_EVENT_PostSave, 0},
{0xfd54fbb7, L"postSign", XFA_EVENT_PostSign, 6},
};
-const XFA_ExecEventParaInfo* GetEventParaInfoByName(FX_WSTR wsEventName)
+const XFA_ExecEventParaInfo* GetEventParaInfoByName(const CFX_WideStringC& wsEventName)
{
int32_t iLength = wsEventName.GetLength();
uint32_t uHash = FX_HashCode_String_GetW(wsEventName.GetPtr(), iLength);
@@ -3504,7 +3504,7 @@ enum XFA_KEYTYPE {
XFA_KEYTYPE_Custom,
XFA_KEYTYPE_Element,
};
-void* XFA_GetMapKey_Custom(FX_WSTR wsKey)
+void* XFA_GetMapKey_Custom(const CFX_WideStringC& wsKey)
{
FX_DWORD dwKey = FX_HashCode_String_GetW(wsKey.GetPtr(), wsKey.GetLength());
return (void*)(uintptr_t)((dwKey << 1) | XFA_KEYTYPE_Custom);
@@ -3526,7 +3526,7 @@ FX_BOOL CXFA_Node::HasAttribute(XFA_ATTRIBUTE eAttr, FX_BOOL bCanInherit )
}
return HasMapModuleKey(pKey, bCanInherit);
}
-FX_BOOL CXFA_Node::SetAttribute(XFA_ATTRIBUTE eAttr, FX_WSTR wsValue, FX_BOOL bNotify )
+FX_BOOL CXFA_Node::SetAttribute(XFA_ATTRIBUTE eAttr, const CFX_WideStringC& wsValue, FX_BOOL bNotify )
{
XFA_LPCATTRIBUTEINFO pAttr = XFA_GetAttributeByID(eAttr);
if (pAttr == NULL) {
@@ -3618,7 +3618,7 @@ FX_BOOL CXFA_Node::GetAttribute(XFA_ATTRIBUTE eAttr, CFX_WideString &wsValue, FX
}
return FALSE;
}
-FX_BOOL CXFA_Node::SetAttribute(FX_WSTR wsAttr, FX_WSTR wsValue, FX_BOOL bNotify)
+FX_BOOL CXFA_Node::SetAttribute(const CFX_WideStringC& wsAttr, const CFX_WideStringC& wsValue, FX_BOOL bNotify)
{
XFA_LPCATTRIBUTEINFO pAttributeInfo = XFA_GetAttributeByName(wsValue);
if (pAttributeInfo) {
@@ -3628,7 +3628,7 @@ FX_BOOL CXFA_Node::SetAttribute(FX_WSTR wsAttr, FX_WSTR wsValue, FX_BOOL bNotify
SetMapModuleString(pKey, wsValue);
return TRUE;
}
-FX_BOOL CXFA_Node::GetAttribute(FX_WSTR wsAttr, CFX_WideString &wsValue, FX_BOOL bUseDefault)
+FX_BOOL CXFA_Node::GetAttribute(const CFX_WideStringC& wsAttr, CFX_WideString &wsValue, FX_BOOL bUseDefault)
{
XFA_LPCATTRIBUTEINFO pAttributeInfo = XFA_GetAttributeByName(wsAttr);
if (pAttributeInfo) {
@@ -3641,7 +3641,7 @@ FX_BOOL CXFA_Node::GetAttribute(FX_WSTR wsAttr, CFX_WideString &wsValue, FX_BOOL
}
return TRUE;
}
-FX_BOOL CXFA_Node::RemoveAttribute(FX_WSTR wsAttr)
+FX_BOOL CXFA_Node::RemoveAttribute(const CFX_WideStringC& wsAttr)
{
void* pKey = XFA_GetMapKey_Custom(wsAttr);
RemoveMapModuleKey(pKey);
@@ -4464,7 +4464,7 @@ FX_BOOL CXFA_Node::RemoveChild(CXFA_Node *pNode, FX_BOOL bNotify)
}
return TRUE;
}
-CXFA_Node* CXFA_Node::GetFirstChildByName(FX_WSTR wsName) const
+CXFA_Node* CXFA_Node::GetFirstChildByName(const CFX_WideStringC& wsName) const
{
return GetFirstChildByName(wsName.IsEmpty() ? 0 : FX_HashCode_String_GetW(wsName.GetPtr(), wsName.GetLength()));
}
@@ -4495,7 +4495,7 @@ CXFA_Node* CXFA_Node::GetNextSameNameSibling(FX_DWORD dwNameHash) const
}
return NULL;
}
-CXFA_Node* CXFA_Node::GetNextSameNameSibling(FX_WSTR wsNodeName) const
+CXFA_Node* CXFA_Node::GetNextSameNameSibling(const CFX_WideStringC& wsNodeName) const
{
return GetNextSameNameSibling(wsNodeName.IsEmpty() ? 0 : FX_HashCode_String_GetW(wsNodeName.GetPtr(), wsNodeName.GetLength()));
}
@@ -4622,7 +4622,7 @@ void CXFA_Node::OnChanged(XFA_ATTRIBUTE eAttr, void* pNewValue, FX_BOOL bNotify,
Script_Attribute_SendAttributeChangeMessage((void*)(uintptr_t)eAttr, pNewValue, bScriptModify);
}
}
-int32_t CXFA_Node::execSingleEventByName(FX_WSTR wsEventName, XFA_ELEMENT eElementType)
+int32_t CXFA_Node::execSingleEventByName(const CFX_WideStringC& wsEventName, XFA_ELEMENT eElementType)
{
int32_t iRet = XFA_EVENTERROR_NotExist;
const XFA_ExecEventParaInfo* eventParaInfo = GetEventParaInfoByName(wsEventName);
@@ -4723,7 +4723,7 @@ FX_BOOL CXFA_Node::GetMapModuleValue(void* pKey, void* &pValue)
}
return FALSE;
}
-void CXFA_Node::SetMapModuleString(void* pKey, FX_WSTR wsValue)
+void CXFA_Node::SetMapModuleString(void* pKey, const CFX_WideStringC& wsValue)
{
SetMapModuleBuffer(pKey, (void*)wsValue.GetPtr(), wsValue.GetLength() * sizeof(FX_WCHAR));
}
@@ -4946,7 +4946,7 @@ CXFA_NodeList::CXFA_NodeList(CXFA_Document* pDocument)
{
m_pDocument->GetScriptContext()->CacheList(this);
}
-CXFA_Node* CXFA_NodeList::NamedItem(FX_WSTR wsName)
+CXFA_Node* CXFA_NodeList::NamedItem(const CFX_WideStringC& wsName)
{
int32_t iCount = GetLength();
FX_DWORD dwHashCode = FX_HashCode_String_GetW(wsName.GetPtr(), wsName.GetLength());
diff --git a/xfa/src/fxfa/src/parser/xfa_objectacc_imp.cpp b/xfa/src/fxfa/src/parser/xfa_objectacc_imp.cpp
index b00b29700f..55f47685d3 100644
--- a/xfa/src/fxfa/src/parser/xfa_objectacc_imp.cpp
+++ b/xfa/src/fxfa/src/parser/xfa_objectacc_imp.cpp
@@ -16,7 +16,7 @@
#include "../common/xfa_localemgr.h"
#include "../common/xfa_fm2jsapi.h"
#include "xfa_debug_parser.h"
-static FX_ARGB XFA_WStringToColor(FX_WSTR wsValue)
+static FX_ARGB XFA_WStringToColor(const CFX_WideStringC& wsValue)
{
uint8_t r = 0, g = 0, b = 0;
if (wsValue.GetLength() == 0) {
@@ -1226,7 +1226,7 @@ int32_t CXFA_Validate::GetScriptTest()
{
return m_pNode->GetEnum(XFA_ATTRIBUTE_ScriptTest);
}
-void CXFA_Validate::GetMessageText(CFX_WideString &wsMessage, FX_WSTR wsMessageType)
+void CXFA_Validate::GetMessageText(CFX_WideString &wsMessage, const CFX_WideStringC& wsMessageType)
{
if (CXFA_Node* pNode = m_pNode->GetProperty(0, XFA_ELEMENT_Message, FALSE)) {
CXFA_Node *pItemNode = pNode->GetNodeItem(XFA_NODEITEM_FirstChild);
@@ -1259,7 +1259,7 @@ void CXFA_Validate::GetNullMessageText(CFX_WideString &wsMessage)
{
GetMessageText(wsMessage, FX_WSTRC(L"nullTest"));
}
-void CXFA_Validate::SetMessageText(CFX_WideString &wsMessage, FX_WSTR wsMessageType)
+void CXFA_Validate::SetMessageText(CFX_WideString &wsMessage, const CFX_WideStringC& wsMessageType)
{
if (CXFA_Node* pNode = m_pNode->GetProperty(0, XFA_ELEMENT_Message, TRUE)) {
CXFA_Node *pItemNode = pNode->GetNodeItem(XFA_NODEITEM_FirstChild);
@@ -2241,7 +2241,7 @@ CXFA_Node* CXFA_WidgetData::GetSelectedMember()
}
return pSelectedMember;
}
-CXFA_Node* CXFA_WidgetData::SetSelectedMember(FX_WSTR wsName, FX_BOOL bNotify)
+CXFA_Node* CXFA_WidgetData::SetSelectedMember(const CFX_WideStringC& wsName, FX_BOOL bNotify)
{
CXFA_Node *pSelectedMember = NULL;
FX_DWORD nameHash = FX_HashCode_String_GetW(wsName.GetPtr(), wsName.GetLength());
@@ -2255,7 +2255,7 @@ CXFA_Node* CXFA_WidgetData::SetSelectedMember(FX_WSTR wsName, FX_BOOL bNotify)
}
return pSelectedMember;
}
-void CXFA_WidgetData::SetSelectedMemberByValue(FX_WSTR wsValue, FX_BOOL bNotify, FX_BOOL bScriptModify, FX_BOOL bSyncData)
+void CXFA_WidgetData::SetSelectedMemberByValue(const CFX_WideStringC& wsValue, FX_BOOL bNotify, FX_BOOL bScriptModify, FX_BOOL bSyncData)
{
CFX_WideString wsExclGroup;
for (CXFA_Node *pNode = m_pNode->GetNodeItem(XFA_NODEITEM_FirstChild); pNode; pNode = pNode->GetNodeItem(XFA_NODEITEM_NextSibling)) {
@@ -2691,7 +2691,7 @@ void CXFA_WidgetData::InsertItem(const CFX_WideString &wsLabel, const CFX_WideSt
}
m_pNode->GetDocument()->GetNotify()->OnWidgetDataEvent(this, XFA_WIDGETEVENT_ListItemAdded, (void*)(const FX_WCHAR*)wsLabel, (void*)(const FX_WCHAR*)wsValue, (void*)(uintptr_t)nIndex);
}
-void CXFA_WidgetData::GetItemLabel(FX_WSTR wsValue, CFX_WideString &wsLabel)
+void CXFA_WidgetData::GetItemLabel(const CFX_WideStringC& wsValue, CFX_WideString &wsLabel)
{
int32_t iCount = 0;
CXFA_NodeArray listitems;
@@ -2735,7 +2735,7 @@ void CXFA_WidgetData::GetItemLabel(FX_WSTR wsValue, CFX_WideString &wsLabel)
}
}
}
-void CXFA_WidgetData::GetItemValue(FX_WSTR wsLabel, CFX_WideString &wsValue)
+void CXFA_WidgetData::GetItemValue(const CFX_WideStringC& wsLabel, CFX_WideString &wsValue)
{
int32_t iCount = 0;
CXFA_NodeArray listitems;
@@ -3516,7 +3516,7 @@ FX_BOOL CXFA_WidgetData::GetValue(CFX_WideString &wsValue, XFA_VALUEPICTURE eVal
}
return TRUE;
}
-FX_BOOL CXFA_WidgetData::GetNormalizeDataValue(FX_WSTR wsValue, CFX_WideString &wsNormalizeValue)
+FX_BOOL CXFA_WidgetData::GetNormalizeDataValue(const CFX_WideStringC& wsValue, CFX_WideString &wsNormalizeValue)
{
wsNormalizeValue = wsValue;
if (wsValue.IsEmpty()) {
@@ -3538,7 +3538,7 @@ FX_BOOL CXFA_WidgetData::GetNormalizeDataValue(FX_WSTR wsValue, CFX_WideString &
}
return FALSE;
}
-FX_BOOL CXFA_WidgetData::GetFormatDataValue(FX_WSTR wsValue, CFX_WideString &wsFormatedValue)
+FX_BOOL CXFA_WidgetData::GetFormatDataValue(const CFX_WideStringC& wsValue, CFX_WideString &wsFormatedValue)
{
wsFormatedValue = wsValue;
if (wsValue.IsEmpty()) {
@@ -3690,7 +3690,7 @@ void CXFA_WidgetData::SyncValue(const CFX_WideString& wsValue, FX_BOOL bNotify)
}
m_pNode->SetContent(wsValue, wsFormatValue, bNotify);
}
-void CXFA_WidgetData::InsertListTextItem(CXFA_Node* pItems, FX_WSTR wsText, int32_t nIndex )
+void CXFA_WidgetData::InsertListTextItem(CXFA_Node* pItems, const CFX_WideStringC& wsText, int32_t nIndex )
{
CXFA_Node* pText = pItems->CreateSamePacketNode(XFA_ELEMENT_Text);
pItems->InsertChild(nIndex, pText);
diff --git a/xfa/src/fxfa/src/parser/xfa_parser_imp.cpp b/xfa/src/fxfa/src/parser/xfa_parser_imp.cpp
index 71ceebf764..82e6739c1e 100644
--- a/xfa/src/fxfa/src/parser/xfa_parser_imp.cpp
+++ b/xfa/src/fxfa/src/parser/xfa_parser_imp.cpp
@@ -195,7 +195,7 @@ void CXFA_SimpleParser::ConstructXFANode(CXFA_Node* pXFANode, IFDE_XMLNode* pXML
}
}
}
-FX_BOOL XFA_FDEExtension_ResolveNamespaceQualifier(IFDE_XMLElement* pNode, FX_WSTR wsQualifier, CFX_WideString& wsNamespaceURI)
+FX_BOOL XFA_FDEExtension_ResolveNamespaceQualifier(IFDE_XMLElement* pNode, const CFX_WideStringC& wsQualifier, CFX_WideString& wsNamespaceURI)
{
if(!pNode) {
return FALSE;
@@ -229,7 +229,7 @@ static inline void XFA_FDEExtension_GetElementTagNamespaceURI(IFDE_XMLElement* p
wsNamespaceURI.Empty();
}
}
-static FX_BOOL XFA_FDEExtension_MatchNodeName(IFDE_XMLNode* pNode, FX_WSTR wsLocalTagName, FX_WSTR wsNamespaceURIPrefix, FX_DWORD eMatchFlags = XFA_XDPPACKET_FLAGS_NOMATCH)
+static FX_BOOL XFA_FDEExtension_MatchNodeName(IFDE_XMLNode* pNode, const CFX_WideStringC& wsLocalTagName, const CFX_WideStringC& wsNamespaceURIPrefix, FX_DWORD eMatchFlags = XFA_XDPPACKET_FLAGS_NOMATCH)
{
if(!pNode || pNode->GetType() != FDE_XMLNODE_Element) {
return FALSE;
@@ -249,7 +249,7 @@ static FX_BOOL XFA_FDEExtension_MatchNodeName(IFDE_XMLNode* pNode, FX_WSTR wsLoc
}
return wsNodeStr == wsNamespaceURIPrefix;
}
-static FX_BOOL XFA_FDEExtension_GetAttributeLocalName(FX_WSTR wsAttributeName, CFX_WideString& wsLocalAttrName)
+static FX_BOOL XFA_FDEExtension_GetAttributeLocalName(const CFX_WideStringC& wsAttributeName, CFX_WideString& wsLocalAttrName)
{
CFX_WideString wsAttrName(wsAttributeName);
FX_STRSIZE iFind = wsAttrName.Find(L':', 0);
@@ -261,7 +261,7 @@ static FX_BOOL XFA_FDEExtension_GetAttributeLocalName(FX_WSTR wsAttributeName, C
return TRUE;
}
}
-static FX_BOOL XFA_FDEExtension_ResolveAttribute(IFDE_XMLElement *pElement, FX_WSTR wsAttributeName, CFX_WideString& wsLocalAttrName, CFX_WideString& wsNamespaceURI)
+static FX_BOOL XFA_FDEExtension_ResolveAttribute(IFDE_XMLElement *pElement, const CFX_WideStringC& wsAttributeName, CFX_WideString& wsLocalAttrName, CFX_WideString& wsNamespaceURI)
{
CFX_WideString wsAttrName(wsAttributeName);
CFX_WideString wsNSPrefix;
@@ -277,7 +277,7 @@ static FX_BOOL XFA_FDEExtension_ResolveAttribute(IFDE_XMLElement *pElement, FX_W
}
return TRUE;
}
-static FX_BOOL XFA_FDEExtension_FindAttributeWithNS(IFDE_XMLElement *pElement, FX_WSTR wsLocalAttributeName, FX_WSTR wsNamespaceURIPrefix, CFX_WideString& wsValue, FX_BOOL bMatchNSAsPrefix = FALSE)
+static FX_BOOL XFA_FDEExtension_FindAttributeWithNS(IFDE_XMLElement *pElement, const CFX_WideStringC& wsLocalAttributeName, const CFX_WideStringC& wsNamespaceURIPrefix, CFX_WideString& wsValue, FX_BOOL bMatchNSAsPrefix = FALSE)
{
if(!pElement) {
return FALSE;
diff --git a/xfa/src/fxfa/src/parser/xfa_script_hostpseudomodel.cpp b/xfa/src/fxfa/src/parser/xfa_script_hostpseudomodel.cpp
index ffbdd6c8ba..697c75d4b1 100644
--- a/xfa/src/fxfa/src/parser/xfa_script_hostpseudomodel.cpp
+++ b/xfa/src/fxfa/src/parser/xfa_script_hostpseudomodel.cpp
@@ -362,7 +362,7 @@ void CScript_HostPseudoModel::Script_HostPseudoModel_DocumentInBatch(CFXJSE_Argu
FXJSE_Value_SetInteger(hValue, iCur);
}
}
-static int32_t XFA_FilterName(FX_WSTR wsExpression, int32_t nStart, CFX_WideString &wsFilter)
+static int32_t XFA_FilterName(const CFX_WideStringC& wsExpression, int32_t nStart, CFX_WideString &wsFilter)
{
FXSYS_assert(nStart > -1);
int32_t iLength = wsExpression.GetLength();
diff --git a/xfa/src/fxfa/src/parser/xfa_script_imp.cpp b/xfa/src/fxfa/src/parser/xfa_script_imp.cpp
index 4dc48f75c7..8e79b75521 100644
--- a/xfa/src/fxfa/src/parser/xfa_script_imp.cpp
+++ b/xfa/src/fxfa/src/parser/xfa_script_imp.cpp
@@ -81,7 +81,7 @@ void CXFA_ScriptContext::Release()
{
delete this;
}
-FX_BOOL CXFA_ScriptContext::RunScript(XFA_SCRIPTLANGTYPE eScriptType, FX_WSTR wsScript, FXJSE_HVALUE hRetValue, CXFA_Object* pThisObject )
+FX_BOOL CXFA_ScriptContext::RunScript(XFA_SCRIPTLANGTYPE eScriptType, const CFX_WideStringC& wsScript, FXJSE_HVALUE hRetValue, CXFA_Object* pThisObject )
{
CFX_ByteString btScript;
XFA_SCRIPTLANGTYPE eSaveType = m_eScriptType;
@@ -132,7 +132,7 @@ FX_BOOL CXFA_ScriptContext::RunScript(XFA_SCRIPTLANGTYPE eScriptType, FX_WSTR ws
m_eScriptType = eSaveType;
return bRet;
}
-void CXFA_ScriptContext::GlobalPropertySetter(FXJSE_HOBJECT hObject, FX_BSTR szPropName, FXJSE_HVALUE hValue)
+void CXFA_ScriptContext::GlobalPropertySetter(FXJSE_HOBJECT hObject, const CFX_ByteStringC& szPropName, FXJSE_HVALUE hValue)
{
CXFA_Object* lpOrginalNode = (CXFA_Object*)FXJSE_Value_ToObject(hObject, NULL);
CXFA_Document* pDoc = lpOrginalNode->GetDocument();
@@ -159,7 +159,7 @@ void CXFA_ScriptContext::GlobalPropertySetter(FXJSE_HOBJECT hObject, FX_BSTR szP
}
pNotify->GetDocProvider()->SetGlobalProperty(pNotify->GetHDOC(), szPropName, hValue);
}
-FX_BOOL CXFA_ScriptContext::QueryNodeByFlag(CXFA_Node* refNode, FX_WSTR propname, FXJSE_HVALUE hValue, FX_DWORD dwFlag, FX_BOOL bSetting)
+FX_BOOL CXFA_ScriptContext::QueryNodeByFlag(CXFA_Node* refNode, const CFX_WideStringC& propname, FXJSE_HVALUE hValue, FX_DWORD dwFlag, FX_BOOL bSetting)
{
XFA_RESOLVENODE_RS resolveRs;
int32_t iRet = ResolveObjects(refNode, propname, resolveRs, dwFlag);
@@ -178,7 +178,7 @@ FX_BOOL CXFA_ScriptContext::QueryNodeByFlag(CXFA_Node* refNode, FX_WSTR propname
}
return bResult;
}
-void CXFA_ScriptContext::GlobalPropertyGetter(FXJSE_HOBJECT hObject, FX_BSTR szPropName, FXJSE_HVALUE hValue)
+void CXFA_ScriptContext::GlobalPropertyGetter(FXJSE_HOBJECT hObject, const CFX_ByteStringC& szPropName, FXJSE_HVALUE hValue)
{
CXFA_Object* pOrginalObject = (CXFA_Object*)FXJSE_Value_ToObject(hObject, NULL);
CXFA_Document* pDoc = pOrginalObject->GetDocument();
@@ -224,7 +224,7 @@ void CXFA_ScriptContext::GlobalPropertyGetter(FXJSE_HOBJECT hObject, FX_BSTR szP
}
pNotify->GetDocProvider()->GetGlobalProperty(pNotify->GetHDOC(), szPropName, hValue);
}
-void CXFA_ScriptContext::NormalPropertyGetter(FXJSE_HOBJECT hObject, FX_BSTR szPropName, FXJSE_HVALUE hValue)
+void CXFA_ScriptContext::NormalPropertyGetter(FXJSE_HOBJECT hObject, const CFX_ByteStringC& szPropName, FXJSE_HVALUE hValue)
{
CXFA_Object* pOrginalObject = (CXFA_Object*)FXJSE_Value_ToObject(hObject, NULL);
if(pOrginalObject == NULL) {
@@ -259,7 +259,7 @@ void CXFA_ScriptContext::NormalPropertyGetter(FXJSE_HOBJECT hObject, FX_BSTR szP
FXJSE_Value_SetUndefined(hValue);
}
}
-void CXFA_ScriptContext::NormalPropertySetter(FXJSE_HOBJECT hObject, FX_BSTR szPropName, FXJSE_HVALUE hValue)
+void CXFA_ScriptContext::NormalPropertySetter(FXJSE_HOBJECT hObject, const CFX_ByteStringC& szPropName, FXJSE_HVALUE hValue)
{
CXFA_Object* pOrginalObject = (CXFA_Object*)FXJSE_Value_ToObject(hObject, NULL);
if(pOrginalObject == NULL) {
@@ -299,7 +299,7 @@ void CXFA_ScriptContext::NormalPropertySetter(FXJSE_HOBJECT hObject, FX_BSTR szP
}
}
}
-int32_t CXFA_ScriptContext::NormalPropTypeGetter(FXJSE_HOBJECT hObject, FX_BSTR szPropName, FX_BOOL bQueryIn)
+int32_t CXFA_ScriptContext::NormalPropTypeGetter(FXJSE_HOBJECT hObject, const CFX_ByteStringC& szPropName, FX_BOOL bQueryIn)
{
CXFA_Object* pObject = (CXFA_Object*)FXJSE_Value_ToObject(hObject, NULL);
if(pObject == NULL) {
@@ -317,7 +317,7 @@ int32_t CXFA_ScriptContext::NormalPropTypeGetter(FXJSE_HOBJECT hObject, FX_BSTR
}
return FXJSE_ClassPropType_Property;
}
-int32_t CXFA_ScriptContext::GlobalPropTypeGetter(FXJSE_HOBJECT hObject, FX_BSTR szPropName, FX_BOOL bQueryIn)
+int32_t CXFA_ScriptContext::GlobalPropTypeGetter(FXJSE_HOBJECT hObject, const CFX_ByteStringC& szPropName, FX_BOOL bQueryIn)
{
CXFA_Object* pObject = (CXFA_Object*)FXJSE_Value_ToObject(hObject, NULL);
if(pObject == NULL) {
@@ -332,7 +332,7 @@ int32_t CXFA_ScriptContext::GlobalPropTypeGetter(FXJSE_HOBJECT hObject, FX_BSTR
}
return FXJSE_ClassPropType_Property;
}
-void CXFA_ScriptContext::NormalMethodCall(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args)
+void CXFA_ScriptContext::NormalMethodCall(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args)
{
CXFA_Object* pObject = (CXFA_Object*)FXJSE_Value_ToObject(hThis, NULL);
if(pObject == NULL) {
@@ -436,7 +436,7 @@ FX_BOOL CXFA_ScriptContext::RunVariablesScript(CXFA_Node* pScriptNode)
}
return TRUE;
}
-FX_BOOL CXFA_ScriptContext::QueryVariableHValue(CXFA_Node* pScriptNode, FX_BSTR szPropName, FXJSE_HVALUE hValue, FX_BOOL bGetter)
+FX_BOOL CXFA_ScriptContext::QueryVariableHValue(CXFA_Node* pScriptNode, const CFX_ByteStringC& szPropName, FXJSE_HVALUE hValue, FX_BOOL bGetter)
{
if(pScriptNode->GetClassID() != XFA_ELEMENT_Script) {
return FALSE;
@@ -470,7 +470,7 @@ FX_BOOL CXFA_ScriptContext::QueryVariableHValue(CXFA_Node* pScriptNode, FX_BSTR
}
return bRes;
}
-FX_BOOL CXFA_ScriptContext::QueryBuiltinHValue(FX_BSTR szPropName, FXJSE_HVALUE hValue)
+FX_BOOL CXFA_ScriptContext::QueryBuiltinHValue(const CFX_ByteStringC& szPropName, FXJSE_HVALUE hValue)
{
void* pBuiltin = NULL;
if ((m_dwBuiltInInFlags & XFA_JSBUILTIN_HasCount) && m_JSBuiltInObjects.Lookup(szPropName, pBuiltin)) {
@@ -524,7 +524,7 @@ void CXFA_ScriptContext::AddJSBuiltinObject(XFA_LPCJSBUILTININFO pBuitinObject)
}
m_JSBuiltInObjects.SetAt(pBuitinObject->pName, (void*)pBuitinObject);
}
-int32_t CXFA_ScriptContext::ResolveObjects(CXFA_Object* refNode, FX_WSTR wsExpression, XFA_RESOLVENODE_RS& resolveNodeRS, FX_DWORD dwStyles, CXFA_Node* bindNode)
+int32_t CXFA_ScriptContext::ResolveObjects(CXFA_Object* refNode, const CFX_WideStringC& wsExpression, XFA_RESOLVENODE_RS& resolveNodeRS, FX_DWORD dwStyles, CXFA_Node* bindNode)
{
if (wsExpression.IsEmpty()) {
return 0;
diff --git a/xfa/src/fxfa/src/parser/xfa_script_imp.h b/xfa/src/fxfa/src/parser/xfa_script_imp.h
index fc43583e8d..d0bcee3669 100644
--- a/xfa/src/fxfa/src/parser/xfa_script_imp.h
+++ b/xfa/src/fxfa/src/parser/xfa_script_imp.h
@@ -25,9 +25,9 @@ public:
{
return m_pEventParam;
}
- virtual FX_BOOL RunScript(XFA_SCRIPTLANGTYPE eScriptType, FX_WSTR wsScript, FXJSE_HVALUE hRetValue, CXFA_Object* pThisObject = NULL);
+ virtual FX_BOOL RunScript(XFA_SCRIPTLANGTYPE eScriptType, const CFX_WideStringC& wsScript, FXJSE_HVALUE hRetValue, CXFA_Object* pThisObject = NULL);
- virtual int32_t ResolveObjects(CXFA_Object* refNode, FX_WSTR wsExpression, XFA_RESOLVENODE_RS& resolveNodeRS, FX_DWORD dwStyles = XFA_RESOLVENODE_Children, CXFA_Node* bindNode = NULL);
+ virtual int32_t ResolveObjects(CXFA_Object* refNode, const CFX_WideStringC& wsExpression, XFA_RESOLVENODE_RS& resolveNodeRS, FX_DWORD dwStyles = XFA_RESOLVENODE_Children, CXFA_Node* bindNode = NULL);
virtual FXJSE_HVALUE GetJSValueFromMap(CXFA_Object* pObject);
virtual void CacheList(CXFA_NodeList* pList)
{
@@ -60,16 +60,16 @@ public:
{
return m_eRunAtType != XFA_ATTRIBUTEENUM_Server;
}
- FX_BOOL QueryNodeByFlag(CXFA_Node* refNode, FX_WSTR propname, FXJSE_HVALUE hValue, FX_DWORD dwFlag, FX_BOOL bSetting);
- FX_BOOL QueryVariableHValue(CXFA_Node* pScriptNode, FX_BSTR szPropName, FXJSE_HVALUE hValue, FX_BOOL bGetter);
- FX_BOOL QueryBuiltinHValue(FX_BSTR szPropName, FXJSE_HVALUE hValue);
- static void GlobalPropertyGetter(FXJSE_HOBJECT hObject, FX_BSTR szPropName, FXJSE_HVALUE hValue);
- static void GlobalPropertySetter(FXJSE_HOBJECT hObject, FX_BSTR szPropName, FXJSE_HVALUE hValue);
- static void NormalPropertyGetter(FXJSE_HOBJECT hObject, FX_BSTR szPropName, FXJSE_HVALUE hValue);
- static void NormalPropertySetter(FXJSE_HOBJECT hObject, FX_BSTR szPropName, FXJSE_HVALUE hValue);
- static void NormalMethodCall(FXJSE_HOBJECT hThis, FX_BSTR szFuncName, CFXJSE_Arguments &args);
- static int32_t NormalPropTypeGetter(FXJSE_HOBJECT hObject, FX_BSTR szPropName, FX_BOOL bQueryIn);
- static int32_t GlobalPropTypeGetter(FXJSE_HOBJECT hObject, FX_BSTR szPropName, FX_BOOL bQueryIn);
+ FX_BOOL QueryNodeByFlag(CXFA_Node* refNode, const CFX_WideStringC& propname, FXJSE_HVALUE hValue, FX_DWORD dwFlag, FX_BOOL bSetting);
+ FX_BOOL QueryVariableHValue(CXFA_Node* pScriptNode, const CFX_ByteStringC& szPropName, FXJSE_HVALUE hValue, FX_BOOL bGetter);
+ FX_BOOL QueryBuiltinHValue(const CFX_ByteStringC& szPropName, FXJSE_HVALUE hValue);
+ static void GlobalPropertyGetter(FXJSE_HOBJECT hObject, const CFX_ByteStringC& szPropName, FXJSE_HVALUE hValue);
+ static void GlobalPropertySetter(FXJSE_HOBJECT hObject, const CFX_ByteStringC& szPropName, FXJSE_HVALUE hValue);
+ static void NormalPropertyGetter(FXJSE_HOBJECT hObject, const CFX_ByteStringC& szPropName, FXJSE_HVALUE hValue);
+ static void NormalPropertySetter(FXJSE_HOBJECT hObject, const CFX_ByteStringC& szPropName, FXJSE_HVALUE hValue);
+ static void NormalMethodCall(FXJSE_HOBJECT hThis, const CFX_ByteStringC& szFuncName, CFXJSE_Arguments &args);
+ static int32_t NormalPropTypeGetter(FXJSE_HOBJECT hObject, const CFX_ByteStringC& szPropName, FX_BOOL bQueryIn);
+ static int32_t GlobalPropTypeGetter(FXJSE_HOBJECT hObject, const CFX_ByteStringC& szPropName, FX_BOOL bQueryIn);
FX_BOOL RunVariablesScript(CXFA_Node* pScriptNode);
CXFA_Object* GetVariablesThis(CXFA_Object* pObject, FX_BOOL bScriptNode = FALSE);
void ReleaseVariablesMap();
diff --git a/xfa/src/fxfa/src/parser/xfa_script_resolveprocessor.cpp b/xfa/src/fxfa/src/parser/xfa_script_resolveprocessor.cpp
index 841176ed69..854e4ba6b9 100644
--- a/xfa/src/fxfa/src/parser/xfa_script_resolveprocessor.cpp
+++ b/xfa/src/fxfa/src/parser/xfa_script_resolveprocessor.cpp
@@ -187,7 +187,7 @@ int32_t CXFA_ResolveProcessor::XFA_ResolveNodes_NumberSign(CXFA_ResolveNodesData
}
return rnd.m_Nodes.GetSize();
}
-int32_t CXFA_ResolveProcessor::XFA_ResolveNodes_ForAttributeRs(CXFA_Object* curNode, CXFA_ResolveNodesData &rnd, FX_WSTR strAttr)
+int32_t CXFA_ResolveProcessor::XFA_ResolveNodes_ForAttributeRs(CXFA_Object* curNode, CXFA_ResolveNodesData &rnd, const CFX_WideStringC& strAttr)
{
XFA_LPCSCRIPTATTRIBUTEINFO lpScriptAttribute = XFA_GetScriptAttributeByName(curNode->GetClassID(), strAttr);
if(lpScriptAttribute) {
@@ -496,7 +496,7 @@ int32_t CXFA_ResolveProcessor::XFA_ResolveNodes_PopStack(CFX_Int32Array &stack)
}
return nType;
}
-int32_t CXFA_ResolveProcessor::XFA_ResolveNodes_GetFilter(FX_WSTR wsExpression, int32_t nStart, CXFA_ResolveNodesData &rnd)
+int32_t CXFA_ResolveProcessor::XFA_ResolveNodes_GetFilter(const CFX_WideStringC& wsExpression, int32_t nStart, CXFA_ResolveNodesData &rnd)
{
FXSYS_assert(nStart > -1);
int32_t iLength = wsExpression.GetLength();
diff --git a/xfa/src/fxfa/src/parser/xfa_script_resolveprocessor.h b/xfa/src/fxfa/src/parser/xfa_script_resolveprocessor.h
index 39153ecfcc..fc13aa9fae 100644
--- a/xfa/src/fxfa/src/parser/xfa_script_resolveprocessor.h
+++ b/xfa/src/fxfa/src/parser/xfa_script_resolveprocessor.h
@@ -51,10 +51,10 @@ public:
int32_t XFA_ResolveNodes_NumberSign(CXFA_ResolveNodesData &rnd);
int32_t XFA_ResolveNodes_Asterisk(CXFA_ResolveNodesData &rnd);
int32_t XFA_ResolveNodes_Normal(CXFA_ResolveNodesData &rnd);
- int32_t XFA_ResolveNodes_ForAttributeRs(CXFA_Object* curNode, CXFA_ResolveNodesData &rnd, FX_WSTR strAttr);
+ int32_t XFA_ResolveNodes_ForAttributeRs(CXFA_Object* curNode, CXFA_ResolveNodesData &rnd, const CFX_WideStringC& strAttr);
void XFA_ResolveNode_ConditionArray(int32_t iCurIndex, CFX_WideString wsCondition, int32_t iFoundCount, CXFA_ResolveNodesData &rnd);
void XFA_ResolveNode_DoPredicateFilter(int32_t iCurIndex, CFX_WideString wsCondition, int32_t iFoundCount, CXFA_ResolveNodesData &rnd);
- int32_t XFA_ResolveNodes_GetFilter(FX_WSTR wsExpression, int32_t nStart, CXFA_ResolveNodesData &rnd);
+ int32_t XFA_ResolveNodes_GetFilter(const CFX_WideStringC& wsExpression, int32_t nStart, CXFA_ResolveNodesData &rnd);
void XFA_ResolveNode_FilterCondition(CXFA_ResolveNodesData &rnd, CFX_WideString wsCondition);
int32_t XFA_ResolveNodes_PopStack(CFX_Int32Array &stack);
void XFA_ResolveNodes_SetStylesForChild(FX_DWORD dwParentStyles, CXFA_ResolveNodesData &rnd);
diff --git a/xfa/src/fxfa/src/parser/xfa_utils_imp.cpp b/xfa/src/fxfa/src/parser/xfa_utils_imp.cpp
index f35602b4be..06cb6d9bd8 100644
--- a/xfa/src/fxfa/src/parser/xfa_utils_imp.cpp
+++ b/xfa/src/fxfa/src/parser/xfa_utils_imp.cpp
@@ -376,7 +376,7 @@ FX_DOUBLE XFA_WideStringToDouble(const CFX_WideString &wsStringVal)
return dValue;
}
-FX_DOUBLE XFA_ByteStringToDouble(FX_BSTR szStringVal)
+FX_DOUBLE XFA_ByteStringToDouble(const CFX_ByteStringC& szStringVal)
{
CFX_WideString wsValue = CFX_WideString::FromUTF8(szStringVal.GetCStr(), szStringVal.GetLength());
return XFA_WideStringToDouble(wsValue);