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

Unified Diff: sky/viewer/internals.cc

Issue 919883002: Allow sky apps to be consumers of mojo services (Closed) Base URL: https://github.com/eseidel/skydart.git@master
Patch Set: cr comments Created 5 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 | « sky/examples/dart-mojo.sky ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/viewer/internals.cc
diff --git a/sky/viewer/internals.cc b/sky/viewer/internals.cc
index 0dcdd42e967c57797885ea70ccb5ea19a07cc4ee..3070f98273ffb79953d5c52b4981e6b345ffee8f 100644
--- a/sky/viewer/internals.cc
+++ b/sky/viewer/internals.cc
@@ -44,10 +44,15 @@ void NotifyTestComplete(Dart_NativeArguments args) {
GetInternals()->NotifyTestComplete(StdStringFromDart(test_result));
}
+void PassShellProxyHandle(Dart_NativeArguments args) {
+ Dart_SetIntegerReturnValue(args, GetInternals()->PassShellProxyHandle().value());
+}
+
const DartBuiltin::Natives kNativeFunctions[] = {
{"renderTreeAsText", RenderTreeAsText, 0},
{"contentAsText", ContentAsText, 0},
{"notifyTestComplete", NotifyTestComplete, 1},
+ {"passShellProxyHandle", PassShellProxyHandle, 0},
};
const DartBuiltin& GetBuiltin() {
@@ -71,6 +76,7 @@ const char kLibrarySource[] = R"DART(
String renderTreeAsText() native "renderTreeAsText";
String contentAsText() native "contentAsText";
void notifyTestComplete(String test_result) native "notifyTestComplete";
+int passShellProxyHandle() native "passShellProxyHandle";
)DART";
} // namespace
« no previous file with comments | « sky/examples/dart-mojo.sky ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698