| Index: content/browser/android/content_view_core_impl.cc
|
| diff --git a/content/browser/android/content_view_core_impl.cc b/content/browser/android/content_view_core_impl.cc
|
| index cf0a7a70cf14d255f475ecac5609378d1c870e6f..016caf2a5b36c77a85e55faf3fd142cb4b0a9a45 100644
|
| --- a/content/browser/android/content_view_core_impl.cc
|
| +++ b/content/browser/android/content_view_core_impl.cc
|
| @@ -230,6 +230,9 @@ void ContentViewCoreImpl::InitWebContents() {
|
| notification_registrar_.Add(
|
| this, NOTIFICATION_RENDERER_PROCESS_CREATED,
|
| content::NotificationService::AllBrowserContextsAndSources());
|
| + notification_registrar_.Add(
|
| + this, NOTIFICATION_WEB_CONTENTS_CONNECTED,
|
| + Source<WebContents>(web_contents_));
|
|
|
| static_cast<WebContentsViewAndroid*>(web_contents_->GetView())->
|
| SetContentViewCore(this);
|
| @@ -281,6 +284,14 @@ void ContentViewCoreImpl::Observe(int type,
|
| }
|
| break;
|
| }
|
| + case NOTIFICATION_WEB_CONTENTS_CONNECTED: {
|
| + JNIEnv* env = AttachCurrentThread();
|
| + ScopedJavaLocalRef<jobject> obj = java_ref_.get(env);
|
| + if (!obj.is_null()) {
|
| + Java_ContentViewCore_onWebContentsConnected(env, obj.obj());
|
| + }
|
| + break;
|
| + }
|
| }
|
| }
|
|
|
|
|