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

Unified Diff: content/shell/renderer/layout_test/interface_registry_js_wrapper.cc

Issue 2405093003: [WIP] Mojo native bindings interface.
Patch Set: fixes webui tests Created 3 years, 10 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
« no previous file with comments | « content/shell/BUILD.gn ('k') | extensions/renderer/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/shell/renderer/layout_test/interface_registry_js_wrapper.cc
diff --git a/content/shell/renderer/layout_test/interface_registry_js_wrapper.cc b/content/shell/renderer/layout_test/interface_registry_js_wrapper.cc
index 7f2a054d4b59ec839505f833e1e73a453df0ec74..ce3526aa510875f2ce25345a37563cadd4729a47 100644
--- a/content/shell/renderer/layout_test/interface_registry_js_wrapper.cc
+++ b/content/shell/renderer/layout_test/interface_registry_js_wrapper.cc
@@ -7,8 +7,18 @@
#include <memory>
#include <utility>
-#include "mojo/edk/js/handle.h"
#include "services/service_manager/public/cpp/interface_registry.h"
+#include "third_party/WebKit/public/web/WebMojoBindings.h"
+
+namespace gin {
+template <>
+struct Converter<mojo::Handle> {
+ static v8::Handle<v8::Value> ToV8(v8::Isolate* isolate, mojo::Handle val) {
+ return blink::WebMojoBindings::wrap(isolate->GetCurrentContext(),
+ mojo::MakeScopedHandle(val));
+ }
+};
+} // namespace gin
namespace content {
« no previous file with comments | « content/shell/BUILD.gn ('k') | extensions/renderer/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698