Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(115)

Unified Diff: third_party/WebKit/Source/bindings/core/v8/ScriptValue.h

Issue 2810843002: bindings: Make the sequence conversion code more complaint with WebIDL. (Closed)
Patch Set: Adjust even more tests Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/bindings/core/v8/ScriptValue.h
diff --git a/third_party/WebKit/Source/bindings/core/v8/ScriptValue.h b/third_party/WebKit/Source/bindings/core/v8/ScriptValue.h
index 98a37d7adf6a74441975407e35fed7d6c0ed9438..f282b6fc537b04263a2cc3541f8f3ed65b9b1687 100644
--- a/third_party/WebKit/Source/bindings/core/v8/ScriptValue.h
+++ b/third_party/WebKit/Source/bindings/core/v8/ScriptValue.h
@@ -174,6 +174,16 @@ class CORE_EXPORT ScriptValue final {
RefPtr<SharedPersistent<v8::Value>> value_;
};
+template <>
+struct NativeValueTraits<ScriptValue>
+ : public NativeValueTraitsBase<ScriptValue> {
+ static inline ScriptValue NativeValue(v8::Isolate* isolate,
+ v8::Local<v8::Value> value,
+ ExceptionState&) {
+ return ScriptValue(ScriptState::Current(isolate), value);
+ }
+};
+
} // namespace blink
#endif // ScriptValue_h

Powered by Google App Engine
This is Rietveld 408576698