summaryrefslogtreecommitdiff
path: root/fpdfsdk/src/javascript/JS_Runtime.cpp
diff options
context:
space:
mode:
authorJochen Eisinger <jochen@chromium.org>2015-05-19 00:38:00 +0200
committerJochen Eisinger <jochen@chromium.org>2015-05-19 00:38:00 +0200
commitdfa2c9939a85ad1c01ef858b21942ab3773dcf27 (patch)
tree064ae26fd633fe7ffcc6c72ce59bd2cfdd429246 /fpdfsdk/src/javascript/JS_Runtime.cpp
parent34d839653f3c7a821dadb8e3219f9a8da83d83e6 (diff)
downloadpdfium-dfa2c9939a85ad1c01ef858b21942ab3773dcf27.tar.xz
Merge V8 API updates to xfa branch
Set pointers in internal fields directly instead of wrapping them Review URL: https://codereview.chromium.org/1139853003 Use phantom handles instead of weak handles Review URL: https://codereview.chromium.org/1129253004 Replace deprecated with non-deprecated V8 APIs Review URL: https://codereview.chromium.org/1126203010 Add myself to OWNERS file Review URL: https://codereview.chromium.org/1133333005 Replace v8::Handle with v8::Local and v8::Persistent with v8::Global Review URL: https://codereview.chromium.org/1138823004 TBR=tsepez@chromium.org BUG= Review URL: https://codereview.chromium.org/1140033004
Diffstat (limited to 'fpdfsdk/src/javascript/JS_Runtime.cpp')
-rw-r--r--fpdfsdk/src/javascript/JS_Runtime.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/fpdfsdk/src/javascript/JS_Runtime.cpp b/fpdfsdk/src/javascript/JS_Runtime.cpp
index 2ad5667b2e..f3d7cf3972 100644
--- a/fpdfsdk/src/javascript/JS_Runtime.cpp
+++ b/fpdfsdk/src/javascript/JS_Runtime.cpp
@@ -106,7 +106,7 @@ void CJS_ArrayBufferAllocator::Free(void* data, size_t length) {
}
/* ------------------------------ CJS_Runtime ------------------------------ */
-extern v8::Persistent<v8::ObjectTemplate>& _getGlobalObjectTemplate(IJS_Runtime* pJSRuntime);
+extern v8::Global<v8::ObjectTemplate>& _getGlobalObjectTemplate(IJS_Runtime* pJSRuntime);
CJS_Runtime::CJS_Runtime(CPDFDoc_Environment* pApp) :
m_pApp(pApp),
m_pDocument(NULL),
@@ -168,7 +168,7 @@ FX_BOOL CJS_Runtime::InitJSObjects()
v8::Isolate::Scope isolate_scope(GetIsolate());
v8::Locker locker(GetIsolate());
v8::HandleScope handle_scope(GetIsolate());
- v8::Handle<v8::Context> context = v8::Context::New(GetIsolate());
+ v8::Local<v8::Context> context = v8::Context::New(GetIsolate());
v8::Context::Scope context_scope(context);
//0 - 8
if (CJS_Border::Init(*this, JS_STATIC) < 0) return FALSE;
@@ -348,7 +348,7 @@ void CJS_Runtime::RemoveEventsInLoop(CJS_FieldEvent* pStart)
}
}
-v8::Handle<v8::Context> CJS_Runtime::NewJSContext()
+v8::Local<v8::Context> CJS_Runtime::NewJSContext()
{
return v8::Local<v8::Context>::New(m_isolate, m_context);
}