| Index: experimental/SkV8Example/JsContext.cpp
|
| diff --git a/experimental/SkV8Example/JsContext.cpp b/experimental/SkV8Example/JsContext.cpp
|
| index cb25daefe0c9d9c981233b853c54914a824e6a1c..5778172f27338c962f56482919fd1d54ba143f29 100644
|
| --- a/experimental/SkV8Example/JsContext.cpp
|
| +++ b/experimental/SkV8Example/JsContext.cpp
|
| @@ -208,7 +208,8 @@ void JsContext::GetWidth(Local<String> name,
|
| JsContext* jsContext = Unwrap(info.This());
|
| SkISize size = jsContext->fCanvas->getDeviceSize();
|
|
|
| - info.GetReturnValue().Set(Int32::New(size.fWidth));
|
| + info.GetReturnValue().Set(
|
| + Int32::New(jsContext->fGlobal->getIsolate(), size.fWidth));
|
| }
|
|
|
| void JsContext::GetHeight(Local<String> name,
|
| @@ -216,7 +217,8 @@ void JsContext::GetHeight(Local<String> name,
|
| JsContext* jsContext = Unwrap(info.This());
|
| SkISize size = jsContext->fCanvas->getDeviceSize();
|
|
|
| - info.GetReturnValue().Set(Int32::New(size.fHeight));
|
| + info.GetReturnValue().Set(
|
| + Int32::New(jsContext->fGlobal->getIsolate(), size.fHeight));
|
| }
|
|
|
|
|
| @@ -226,7 +228,7 @@ Persistent<ObjectTemplate> JsContext::gContextTemplate;
|
| result->Set(String::NewFromUtf8( \
|
| fGlobal->getIsolate(), name, \
|
| String::kInternalizedString), \
|
| - FunctionTemplate::New(fn))
|
| + FunctionTemplate::New(fGlobal->getIsolate(), fn))
|
|
|
| Handle<ObjectTemplate> JsContext::makeContextTemplate() {
|
| EscapableHandleScope handleScope(fGlobal->getIsolate());
|
|
|