From 275e260a6cd4a8e506ba974feb85ebcd926c1739 Mon Sep 17 00:00:00 2001 From: Ryan Harrison Date: Mon, 18 Sep 2017 14:23:18 -0400 Subject: Convert string class names Automated using git grep & sed. Replace StringC classes with StringView classes. Remove the CFX_ prefix and put string classes in fxcrt namespace. Change AsStringC() to AsStringView(). Rename tests from TEST(fxcrt, *String*Foo) to TEST(*String*, Foo). Couple of tests needed to have their names regularlized. BUG=pdfium:894 Change-Id: I7ca038685c8d803795f3ed02545124f7a224c83d Reviewed-on: https://pdfium-review.googlesource.com/14151 Reviewed-by: Tom Sepez Commit-Queue: Ryan Harrison --- fpdfsdk/javascript/app.h | 82 +++++++++++++++++++++--------------------------- 1 file changed, 35 insertions(+), 47 deletions(-) (limited to 'fpdfsdk/javascript/app.h') diff --git a/fpdfsdk/javascript/app.h b/fpdfsdk/javascript/app.h index 0a2cfdb58e..e77c8cd57b 100644 --- a/fpdfsdk/javascript/app.h +++ b/fpdfsdk/javascript/app.h @@ -41,132 +41,120 @@ class app : public CJS_EmbedObj { explicit app(CJS_Object* pJSObject); ~app() override; - bool activeDocs(CJS_Runtime* pRuntime, - CJS_PropValue& vp, - CFX_WideString& sError); - bool calculate(CJS_Runtime* pRuntime, - CJS_PropValue& vp, - CFX_WideString& sError); + bool activeDocs(CJS_Runtime* pRuntime, CJS_PropValue& vp, WideString& sError); + bool calculate(CJS_Runtime* pRuntime, CJS_PropValue& vp, WideString& sError); bool formsVersion(CJS_Runtime* pRuntime, CJS_PropValue& vp, - CFX_WideString& sError); - bool fs(CJS_Runtime* pRuntime, CJS_PropValue& vp, CFX_WideString& sError); - bool fullscreen(CJS_Runtime* pRuntime, - CJS_PropValue& vp, - CFX_WideString& sError); - bool language(CJS_Runtime* pRuntime, - CJS_PropValue& vp, - CFX_WideString& sError); - bool media(CJS_Runtime* pRuntime, CJS_PropValue& vp, CFX_WideString& sError); - bool platform(CJS_Runtime* pRuntime, - CJS_PropValue& vp, - CFX_WideString& sError); + WideString& sError); + bool fs(CJS_Runtime* pRuntime, CJS_PropValue& vp, WideString& sError); + bool fullscreen(CJS_Runtime* pRuntime, CJS_PropValue& vp, WideString& sError); + bool language(CJS_Runtime* pRuntime, CJS_PropValue& vp, WideString& sError); + bool media(CJS_Runtime* pRuntime, CJS_PropValue& vp, WideString& sError); + bool platform(CJS_Runtime* pRuntime, CJS_PropValue& vp, WideString& sError); bool runtimeHighlight(CJS_Runtime* pRuntime, CJS_PropValue& vp, - CFX_WideString& sError); - bool viewerType(CJS_Runtime* pRuntime, - CJS_PropValue& vp, - CFX_WideString& sError); + WideString& sError); + bool viewerType(CJS_Runtime* pRuntime, CJS_PropValue& vp, WideString& sError); bool viewerVariation(CJS_Runtime* pRuntime, CJS_PropValue& vp, - CFX_WideString& sError); + WideString& sError); bool viewerVersion(CJS_Runtime* pRuntime, CJS_PropValue& vp, - CFX_WideString& sError); + WideString& sError); bool alert(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool beep(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool browseForDoc(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool clearInterval(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool clearTimeOut(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool execDialog(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool execMenuItem(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool findComponent(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool goBack(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool goForward(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool launchURL(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool mailMsg(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool newFDF(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool newDoc(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool openDoc(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool openFDF(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool popUpMenuEx(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool popUpMenu(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool response(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool setInterval(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); bool setTimeOut(CJS_Runtime* pRuntime, const std::vector& params, CJS_Value& vRet, - CFX_WideString& sError); + WideString& sError); void TimerProc(GlobalTimer* pTimer); void CancelProc(GlobalTimer* pTimer); - static CFX_WideString SysPathToPDFPath(const CFX_WideString& sOldPath); + static WideString SysPathToPDFPath(const WideString& sOldPath); private: // CJS_EmbedObj - void RunJsScript(CJS_Runtime* pRuntime, const CFX_WideString& wsScript); + void RunJsScript(CJS_Runtime* pRuntime, const WideString& wsScript); void ClearTimerCommon(CJS_Runtime* pRuntime, const CJS_Value& param); -- cgit v1.2.3