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

Side by Side Diff: content/browser/android/content_view_core_impl.cc

Issue 2178973004: DialogSurfaceManager implementation. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: removed IDialogSurfaceActivityMapper from common.aidl Created 4 years 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 unified diff | Download patch
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/android/content_view_core_impl.h" 5 #include "content/browser/android/content_view_core_impl.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include "base/android/jni_android.h" 9 #include "base/android/jni_android.h"
10 #include "base/android/jni_array.h" 10 #include "base/android/jni_array.h"
(...skipping 277 matching lines...) Expand 10 before | Expand all | Expand 10 after
288 return; 288 return;
289 if (GetWindowAndroid()) { 289 if (GetWindowAndroid()) {
290 for (auto& observer : observer_list_) 290 for (auto& observer : observer_list_)
291 observer.OnDetachedFromWindow(); 291 observer.OnDetachedFromWindow();
292 view->RemoveFromParent(); 292 view->RemoveFromParent();
293 } 293 }
294 if (window) { 294 if (window) {
295 window->AddChild(view); 295 window->AddChild(view);
296 for (auto& observer : observer_list_) 296 for (auto& observer : observer_list_)
297 observer.OnAttachedToWindow(); 297 observer.OnAttachedToWindow();
298 Java_ContentViewCore_onAttachedToWindowAndroid(env, obj.obj());
299 } else {
300 Java_ContentViewCore_onDetachedFromWindowAndroid(env, obj.obj());
298 } 301 }
299 } 302 }
300 303
301 base::android::ScopedJavaLocalRef<jobject> 304 base::android::ScopedJavaLocalRef<jobject>
302 ContentViewCoreImpl::GetWebContentsAndroid(JNIEnv* env, 305 ContentViewCoreImpl::GetWebContentsAndroid(JNIEnv* env,
303 const JavaParamRef<jobject>& obj) { 306 const JavaParamRef<jobject>& obj) {
304 return web_contents_->GetJavaWebContents(); 307 return web_contents_->GetJavaWebContents();
305 } 308 }
306 309
307 base::android::ScopedJavaLocalRef<jobject> 310 base::android::ScopedJavaLocalRef<jobject>
(...skipping 1279 matching lines...) Expand 10 before | Expand all | Expand 10 after
1587 return ScopedJavaLocalRef<jobject>(); 1590 return ScopedJavaLocalRef<jobject>();
1588 1591
1589 return view->GetJavaObject(); 1592 return view->GetJavaObject();
1590 } 1593 }
1591 1594
1592 bool RegisterContentViewCore(JNIEnv* env) { 1595 bool RegisterContentViewCore(JNIEnv* env) {
1593 return RegisterNativesImpl(env); 1596 return RegisterNativesImpl(env);
1594 } 1597 }
1595 1598
1596 } // namespace content 1599 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698