Index: third_party/WebKit/Source/core/events/MessageEvent.cpp |
diff --git a/third_party/WebKit/Source/core/events/MessageEvent.cpp b/third_party/WebKit/Source/core/events/MessageEvent.cpp |
index bceaf11d6387f00c6f88ced2c19537dcc9fffb31..8622937c3278307fe8b6cd1f82eac990e7ce602a 100644 |
--- a/third_party/WebKit/Source/core/events/MessageEvent.cpp |
+++ b/third_party/WebKit/Source/core/events/MessageEvent.cpp |
@@ -30,6 +30,7 @@ |
#include "bindings/core/v8/ExceptionMessages.h" |
#include "bindings/core/v8/ExceptionState.h" |
#include "bindings/core/v8/V8ArrayBuffer.h" |
+#include "bindings/core/v8/V8PrivateProperty.h" |
namespace blink { |
@@ -218,18 +219,18 @@ v8::Local<v8::Object> MessageEvent::associateWithWrapper(v8::Isolate* isolate, c |
// Ensures a wrapper is created for the data to return now so that V8 knows how |
// much memory is used via the wrapper. To keep the wrapper alive, it's set to |
- // the wrapper of the MessageEvent as a hidden value. |
+ // the wrapper of the MessageEvent as a private value. |
switch (getDataType()) { |
case MessageEvent::DataTypeScriptValue: |
case MessageEvent::DataTypeSerializedScriptValue: |
break; |
case MessageEvent::DataTypeString: |
- V8HiddenValue::setHiddenValue(ScriptState::current(isolate), wrapper, V8HiddenValue::stringData(isolate), v8String(isolate, dataAsString())); |
+ V8PrivateProperty::getMessageEventCachedData(isolate).set(wrapper, v8String(isolate, dataAsString())); |
haraken
2016/05/24 17:33:53
Another possible API would be:
V8PrivatePropert
Ken Russell (switch to Gerrit)
2016/05/24 21:49:18
In this scenario, would the private property be as
Yuki
2016/05/26 10:52:11
Symbol class only holds two simple members, so the
|
break; |
case MessageEvent::DataTypeBlob: |
break; |
case MessageEvent::DataTypeArrayBuffer: |
- V8HiddenValue::setHiddenValue(ScriptState::current(isolate), wrapper, V8HiddenValue::arrayBufferData(isolate), toV8(dataAsArrayBuffer(), wrapper, isolate)); |
+ V8PrivateProperty::getMessageEventCachedData(isolate).set(wrapper, toV8(dataAsArrayBuffer(), wrapper, isolate)); |
break; |
} |