Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(387)

Unified Diff: fpdfsdk/src/javascript/Field.cpp

Issue 1332973002: Remove some abstractions in fxjs_v8.h. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Remove implicit cast operator from CJS_Runtime. Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « fpdfsdk/src/javascript/Document.cpp ('k') | fpdfsdk/src/javascript/JS_Context.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: fpdfsdk/src/javascript/Field.cpp
diff --git a/fpdfsdk/src/javascript/Field.cpp b/fpdfsdk/src/javascript/Field.cpp
index c44636872b94ad929f4ddf2e1926f628c523e833..a0570cb56c61d954080297b1263a226a880c0aab 100644
--- a/fpdfsdk/src/javascript/Field.cpp
+++ b/fpdfsdk/src/javascript/Field.cpp
@@ -3315,8 +3315,9 @@ FX_BOOL Field::buttonGetIcon(IFXJS_Context* cc,
CJS_Runtime* pRuntime = pContext->GetJSRuntime();
ASSERT(pRuntime != NULL);
- JSFXObject pObj = JS_NewFxDynamicObj(*pRuntime, pContext,
- JS_GetObjDefnID(*pRuntime, L"Icon"));
+ v8::Local<v8::Object> pObj =
+ JS_NewFxDynamicObj(pRuntime->GetIsolate(), pContext,
+ JS_GetObjDefnID(pRuntime->GetIsolate(), L"Icon"));
ASSERT(pObj.IsEmpty() == FALSE);
CJS_Icon* pJS_Icon = (CJS_Icon*)JS_GetPrivate(pObj);
@@ -3530,8 +3531,9 @@ FX_BOOL Field::getArray(IFXJS_Context* cc,
for (int j = 0, jsz = swSort.GetSize(); j < jsz; j++) {
CFX_WideString* pStr = swSort.GetAt(j);
- JSFXObject pObj = JS_NewFxDynamicObj(*pRuntime, pContext,
- JS_GetObjDefnID(*pRuntime, L"Field"));
+ v8::Local<v8::Object> pObj =
+ JS_NewFxDynamicObj(pRuntime->GetIsolate(), pContext,
+ JS_GetObjDefnID(pRuntime->GetIsolate(), L"Field"));
ASSERT(pObj.IsEmpty() == FALSE);
CJS_Field* pJSField = (CJS_Field*)JS_GetPrivate(pObj);
« no previous file with comments | « fpdfsdk/src/javascript/Document.cpp ('k') | fpdfsdk/src/javascript/JS_Context.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698