| OLD | NEW |
| (Empty) |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #include "sky/shell/java_service_provider.h" | |
| 6 | |
| 7 #include "base/android/jni_android.h" | |
| 8 #include "jni/JavaServiceProvider_jni.h" | |
| 9 #include "mojo/public/cpp/bindings/interface_request.h" | |
| 10 | |
| 11 namespace sky { | |
| 12 namespace shell { | |
| 13 | |
| 14 bool RegisterJavaServiceProvider(JNIEnv* env) { | |
| 15 return RegisterNativesImpl(env); | |
| 16 } | |
| 17 | |
| 18 void CreateJavaServiceProvider( | |
| 19 mojo::InterfaceRequest<mojo::ServiceProvider> request) { | |
| 20 Java_JavaServiceProvider_create( | |
| 21 base::android::AttachCurrentThread(), | |
| 22 base::android::GetApplicationContext(), | |
| 23 request.PassMessagePipe().release().value()); | |
| 24 } | |
| 25 | |
| 26 } // namespace shell | |
| 27 } // namespace sky | |
| OLD | NEW |