From d6e9cfaab0555c34783dd05261329866b4da1b9f Mon Sep 17 00:00:00 2001 From: Dan Sinclair Date: Mon, 30 Oct 2017 21:19:42 +0000 Subject: Convert JS resource into enum class This CL converts the #defines into an enum class. Change-Id: I895e29e1d46a7a82d7be896f5776eb00d28559f5 Reviewed-on: https://pdfium-review.googlesource.com/17091 Commit-Queue: dsinclair Reviewed-by: Tom Sepez --- fxjs/cjs_global.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'fxjs/cjs_global.cpp') diff --git a/fxjs/cjs_global.cpp b/fxjs/cjs_global.cpp index 3c5c51b794..0fef8d5334 100644 --- a/fxjs/cjs_global.cpp +++ b/fxjs/cjs_global.cpp @@ -346,12 +346,12 @@ CJS_Return JSGlobalAlternate::setPersistent( CJS_Runtime* pRuntime, const std::vector>& params) { if (params.size() != 2) - return CJS_Return(JSGetStringFromID(IDS_STRING_JSPARAMERROR)); + return CJS_Return(JSGetStringFromID(JSMessage::kParamError)); auto it = m_MapGlobal.find( ByteString::FromUnicode(pRuntime->ToWideString(params[0]))); if (it == m_MapGlobal.end() || it->second->bDeleted) - return CJS_Return(JSGetStringFromID(IDS_STRING_JSNOGLOBAL)); + return CJS_Return(JSGetStringFromID(JSMessage::kGlobalNotFoundError)); it->second->bPersistent = pRuntime->ToBoolean(params[1]); return CJS_Return(true); -- cgit v1.2.3