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

Unified Diff: blimp/client/core/android/blimp_client_context_impl_android.cc

Issue 2191743002: Setup the delegate in Chrome, so we may put chrome java functions we need in blimp to the delegate … (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased. Created 4 years, 4 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: blimp/client/core/android/blimp_client_context_impl_android.cc
diff --git a/blimp/client/core/android/blimp_client_context_impl_android.cc b/blimp/client/core/android/blimp_client_context_impl_android.cc
index 24ec524a2adbb89e610046174ec49e3a44d1b98a..f308ef162daba130a951d38ee90f9188f6b9cfd2 100644
--- a/blimp/client/core/android/blimp_client_context_impl_android.cc
+++ b/blimp/client/core/android/blimp_client_context_impl_android.cc
@@ -8,6 +8,7 @@
#include "base/android/scoped_java_ref.h"
#include "blimp/client/core/contents/blimp_contents_impl.h"
#include "blimp/client/public/blimp_client_context.h"
+#include "blimp/client/public/blimp_client_context_delegate.h"
#include "jni/BlimpClientContextImpl_jni.h"
namespace blimp {
@@ -69,5 +70,13 @@ BlimpClientContextImplAndroid::CreateBlimpContentsJava(JNIEnv* env,
return blimp_contents_impl->GetJavaBlimpContentsImpl();
}
+base::android::ScopedJavaLocalRef<jobject>
+ BlimpClientContextImplAndroid::GetDelegateJavaObject(
+ JNIEnv* env, jobject jobj) {
+ BlimpClientContextDelegate* delegate = GetDelegate();
+ return delegate ? delegate->GetJavaObject() :
+ base::android::ScopedJavaLocalRef<jobject>();
+}
+
} // namespace client
} // namespace blimp

Powered by Google App Engine
This is Rietveld 408576698