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

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

Issue 2060753002: Implement script-side of callback reactions for Custom Elements V1 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@callback-ce
Patch Set: rebase Created 4 years, 6 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/V8Binding.h
diff --git a/third_party/WebKit/Source/bindings/core/v8/V8Binding.h b/third_party/WebKit/Source/bindings/core/v8/V8Binding.h
index e81bdd29998b3d137c3d5cc2807352d5ab37e358..f18e9c4a9ed0bc5ad2d016ae31ccb8b69524a40d 100644
--- a/third_party/WebKit/Source/bindings/core/v8/V8Binding.h
+++ b/third_party/WebKit/Source/bindings/core/v8/V8Binding.h
@@ -407,6 +407,13 @@ inline v8::Local<v8::String> v8String(v8::Isolate* isolate, const String& string
return V8PerIsolateData::from(isolate)->getStringCache()->v8ExternalString(isolate, string.impl());
}
+inline v8::Local<v8::Value> v8StringOrNull(v8::Isolate* isolate, const AtomicString& string)
+{
+ if (string.isNull())
+ return v8::Null(isolate);
+ return V8PerIsolateData::from(isolate)->getStringCache()->v8ExternalString(isolate, string.impl());
+}
+
inline v8::Local<v8::String> v8String(v8::Isolate* isolate, const CompressibleString& string)
{
if (string.isNull())

Powered by Google App Engine
This is Rietveld 408576698