summaryrefslogtreecommitdiff
path: root/fxjs/cjs_field.cpp
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2017-10-30 21:19:42 +0000
committerChromium commit bot <commit-bot@chromium.org>2017-10-30 21:19:42 +0000
commitd6e9cfaab0555c34783dd05261329866b4da1b9f (patch)
treef123e3ee82017c1e14a07306f54381ea9bf2966c /fxjs/cjs_field.cpp
parentcaee9596e926a41a23fa0ddebd10d509db4b23ab (diff)
downloadpdfium-chromium/3254.tar.xz
Convert JS resource into enum classchromium/3254
This CL converts the #defines into an enum class. Change-Id: I895e29e1d46a7a82d7be896f5776eb00d28559f5 Reviewed-on: https://pdfium-review.googlesource.com/17091 Commit-Queue: dsinclair <dsinclair@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org>
Diffstat (limited to 'fxjs/cjs_field.cpp')
-rw-r--r--fxjs/cjs_field.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/fxjs/cjs_field.cpp b/fxjs/cjs_field.cpp
index 51f8c5aafc..cb8eb6bfcb 100644
--- a/fxjs/cjs_field.cpp
+++ b/fxjs/cjs_field.cpp
@@ -1418,7 +1418,7 @@ CJS_Return Field::get_page(CJS_Runtime* pRuntime) {
int i = 0;
for (const auto& pObserved : widgets) {
if (!pObserved)
- return CJS_Return(JSGetStringFromID(IDS_STRING_JSBADOBJECT));
+ return CJS_Return(JSGetStringFromID(JSMessage::kBadObjectError));
auto* pWidget = static_cast<CPDFSDK_Widget*>(pObserved.Get());
CPDFSDK_PageView* pPageView = pWidget->GetPageView();
@@ -1434,7 +1434,7 @@ CJS_Return Field::get_page(CJS_Runtime* pRuntime) {
}
CJS_Return Field::set_page(CJS_Runtime* pRuntime, v8::Local<v8::Value> vp) {
- return CJS_Return(JSGetStringFromID(IDS_STRING_JSREADONLY));
+ return CJS_Return(JSGetStringFromID(JSMessage::kReadOnlyError));
}
CJS_Return Field::get_password(CJS_Runtime* pRuntime) {