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

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

Issue 2840163002: DOM: NodeIterator.filter and TreeWalker.filter should return values which were specified to createN… (Closed)
Patch Set: Move ToV8() to ToV8ForCore.h, etc. 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/ToV8ForCore.h
diff --git a/third_party/WebKit/Source/bindings/core/v8/ToV8ForCore.h b/third_party/WebKit/Source/bindings/core/v8/ToV8ForCore.h
index 96cd46bf16f20225dd202eb25c83698a5becb0ff..be7c1ebc591256931b20c4a88aa0255240ed1676 100644
--- a/third_party/WebKit/Source/bindings/core/v8/ToV8ForCore.h
+++ b/third_party/WebKit/Source/bindings/core/v8/ToV8ForCore.h
@@ -9,6 +9,7 @@
// handle. Call sites must check IsEmpty() before using return value.
#include "bindings/core/v8/ToV8.h"
+#include "bindings/core/v8/V8NodeFilterCondition.h"
#include "core/dom/ArrayBufferViewHelpers.h"
#include "v8/include/v8.h"
@@ -30,6 +31,12 @@ inline v8::Local<v8::Value> ToV8(NotShared<T> value,
return ToV8(value.View(), creation_context, isolate);
}
+inline v8::Local<v8::Value> ToV8(const V8NodeFilterCondition* value,
+ v8::Local<v8::Object> creation_context,
+ v8::Isolate* isolate) {
+ return value ? value->Callback(isolate) : v8::Null(isolate).As<v8::Value>();
+}
+
} // namespace blink
#endif // ToV8ForCore_h

Powered by Google App Engine
This is Rietveld 408576698