| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 "components/web_contents_delegate_android/web_contents_delegate_android
.h" | 5 #include "components/web_contents_delegate_android/web_contents_delegate_android
.h" |
| 6 | 6 |
| 7 #include <android/keycodes.h> | 7 #include <android/keycodes.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 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 212 return true; | 212 return true; |
| 213 return Java_WebContentsDelegateAndroid_onGoToEntryOffset(env, obj, offset); | 213 return Java_WebContentsDelegateAndroid_onGoToEntryOffset(env, obj, offset); |
| 214 } | 214 } |
| 215 | 215 |
| 216 void WebContentsDelegateAndroid::WebContentsCreated( | 216 void WebContentsDelegateAndroid::WebContentsCreated( |
| 217 WebContents* source_contents, | 217 WebContents* source_contents, |
| 218 int opener_render_process_id, | 218 int opener_render_process_id, |
| 219 int opener_render_frame_id, | 219 int opener_render_frame_id, |
| 220 const std::string& frame_name, | 220 const std::string& frame_name, |
| 221 const GURL& target_url, | 221 const GURL& target_url, |
| 222 WebContents* new_contents, | 222 WebContents* new_contents) { |
| 223 const base::Optional<content::WebContents::CreateParams>& create_params) { | |
| 224 JNIEnv* env = AttachCurrentThread(); | 223 JNIEnv* env = AttachCurrentThread(); |
| 225 ScopedJavaLocalRef<jobject> obj = GetJavaDelegate(env); | 224 ScopedJavaLocalRef<jobject> obj = GetJavaDelegate(env); |
| 226 if (obj.is_null()) | 225 if (obj.is_null()) |
| 227 return; | 226 return; |
| 228 | 227 |
| 229 ScopedJavaLocalRef<jobject> jsource_contents; | 228 ScopedJavaLocalRef<jobject> jsource_contents; |
| 230 if (source_contents) | 229 if (source_contents) |
| 231 jsource_contents = source_contents->GetJavaWebContents(); | 230 jsource_contents = source_contents->GetJavaWebContents(); |
| 232 ScopedJavaLocalRef<jobject> jnew_contents; | 231 ScopedJavaLocalRef<jobject> jnew_contents; |
| 233 if (new_contents) | 232 if (new_contents) |
| (...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 414 validation_message_bubble_->SetPositionRelativeToAnchor( | 413 validation_message_bubble_->SetPositionRelativeToAnchor( |
| 415 rwhv->GetRenderWidgetHost(), anchor_in_root_view); | 414 rwhv->GetRenderWidgetHost(), anchor_in_root_view); |
| 416 } | 415 } |
| 417 } | 416 } |
| 418 | 417 |
| 419 void WebContentsDelegateAndroid::RequestAppBannerFromDevTools( | 418 void WebContentsDelegateAndroid::RequestAppBannerFromDevTools( |
| 420 content::WebContents* web_contents) { | 419 content::WebContents* web_contents) { |
| 421 } | 420 } |
| 422 | 421 |
| 423 } // namespace web_contents_delegate_android | 422 } // namespace web_contents_delegate_android |
| OLD | NEW |