Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: src/JsValue.cpp

Issue 6112412478472192: Issue 1547 - Pass isolate to v8::API (Closed)
Patch Set: Created Nov. 10, 2014, 9:05 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/JsValue.cpp
===================================================================
--- a/src/JsValue.cpp
+++ b/src/JsValue.cpp
@@ -146,7 +146,7 @@
throw new std::runtime_error("Attempting to get property of a non-object");
const JsContext context(jsEngine);
- v8::Local<v8::String> property = Utils::ToV8String(name);
+ v8::Local<v8::String> property = Utils::ToV8String(jsEngine->isolate, name);
v8::Local<v8::Object> obj = v8::Local<v8::Object>::Cast(UnwrapValue());
return JsValuePtr(new JsValue(jsEngine, obj->Get(property)));
}
@@ -156,7 +156,7 @@
if (!IsObject())
throw new std::runtime_error("Attempting to set property on a non-object");
- v8::Local<v8::String> property = Utils::ToV8String(name);
+ v8::Local<v8::String> property = Utils::ToV8String(jsEngine->isolate, name);
v8::Local<v8::Object> obj = v8::Local<v8::Object>::Cast(UnwrapValue());
obj->Set(property, val);
}
@@ -169,13 +169,13 @@
void AdblockPlus::JsValue::SetProperty(const std::string& name, const std::string& val)
{
const JsContext context(jsEngine);
- SetProperty(name, Utils::ToV8String(val));
+ SetProperty(name, Utils::ToV8String(jsEngine->isolate, val));
}
void AdblockPlus::JsValue::SetProperty(const std::string& name, int64_t val)
{
const JsContext context(jsEngine);
- SetProperty(name, v8::Number::New(val));
+ SetProperty(name, v8::Number::New(jsEngine->isolate, val));
}
void AdblockPlus::JsValue::SetProperty(const std::string& name, const JsValuePtr& val)

Powered by Google App Engine
This is Rietveld