| Index: Source/bindings/v8/custom/V8InjectedScriptHostCustom.cpp
|
| diff --git a/Source/bindings/v8/custom/V8InjectedScriptHostCustom.cpp b/Source/bindings/v8/custom/V8InjectedScriptHostCustom.cpp
|
| index b044dbe8b2bc698bb36ffc0338113d4df8983926..4d21bac180129f91b9f9ffd34785968e70113a7a 100644
|
| --- a/Source/bindings/v8/custom/V8InjectedScriptHostCustom.cpp
|
| +++ b/Source/bindings/v8/custom/V8InjectedScriptHostCustom.cpp
|
| @@ -46,6 +46,7 @@
|
| #include "V8Uint8Array.h"
|
| #include "V8Uint8ClampedArray.h"
|
| #include "bindings/tests/results/V8Float64Array.h"
|
| +#include "bindings/dart/DartHandleProxy.h"
|
| #include "bindings/v8/BindingSecurity.h"
|
| #include "bindings/v8/ScriptDebugServer.h"
|
| #include "bindings/v8/ScriptValue.h"
|
| @@ -63,9 +64,15 @@ namespace WebCore {
|
|
|
| Node* InjectedScriptHost::scriptValueAsNode(ScriptValue value)
|
| {
|
| + v8::HandleScope scope;
|
| if (!value.isObject() || value.isNull())
|
| return 0;
|
| - return V8Node::toNative(v8::Handle<v8::Object>::Cast(value.v8ValueRaw()));
|
| +
|
| + v8::Handle<v8::Object> handle = v8::Handle<v8::Object>::Cast(value.v8ValueRaw());
|
| + if (DartHandleProxy::isDartProxy(handle))
|
| + return DartHandleProxy::toNativeNode(handle);
|
| +
|
| + return V8Node::toNative(handle);
|
| }
|
|
|
| ScriptValue InjectedScriptHost::nodeAsScriptValue(ScriptState* state, Node* node)
|
| @@ -177,6 +184,12 @@ void V8InjectedScriptHost::typeMethodCustom(const v8::FunctionCallbackInfo<v8::V
|
| v8SetReturnValue(args, v8::String::NewSymbol("array"));
|
| return;
|
| }
|
| + if (DartHandleProxy::isDartProxy(value)) {
|
| + const char* type = DartHandleProxy::getType(value);
|
| + if (type != 0)
|
| + v8SetReturnValue(args, v8::String::NewSymbol(type));
|
| + return;
|
| + }
|
| }
|
|
|
| void V8InjectedScriptHost::functionDetailsMethodCustom(const v8::FunctionCallbackInfo<v8::Value>& args)
|
|
|