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 #ifndef COMPONENTS_WEB_CONTENTS_DELEGATE_ANDROID_WEB_CONTENTS_DELEGATE_ANDROID_H
_ | 5 #ifndef COMPONENTS_WEB_CONTENTS_DELEGATE_ANDROID_WEB_CONTENTS_DELEGATE_ANDROID_H
_ |
6 #define COMPONENTS_WEB_CONTENTS_DELEGATE_ANDROID_WEB_CONTENTS_DELEGATE_ANDROID_H
_ | 6 #define COMPONENTS_WEB_CONTENTS_DELEGATE_ANDROID_WEB_CONTENTS_DELEGATE_ANDROID_H
_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <memory> | 10 #include <memory> |
11 | 11 |
12 #include "base/android/jni_weak_ref.h" | 12 #include "base/android/jni_weak_ref.h" |
13 #include "base/android/scoped_java_ref.h" | 13 #include "base/android/scoped_java_ref.h" |
14 #include "base/compiler_specific.h" | 14 #include "base/compiler_specific.h" |
15 #include "content/public/browser/web_contents.h" | |
16 #include "content/public/browser/web_contents_delegate.h" | 15 #include "content/public/browser/web_contents_delegate.h" |
17 | 16 |
18 class GURL; | 17 class GURL; |
19 | 18 |
20 namespace content { | 19 namespace content { |
| 20 class WebContents; |
21 class WebContentsDelegate; | 21 class WebContentsDelegate; |
22 struct NativeWebKeyboardEvent; | 22 struct NativeWebKeyboardEvent; |
23 struct OpenURLParams; | 23 struct OpenURLParams; |
24 } | 24 } |
25 | 25 |
26 namespace web_contents_delegate_android { | 26 namespace web_contents_delegate_android { |
27 | 27 |
28 class ValidationMessageBubbleAndroid; | 28 class ValidationMessageBubbleAndroid; |
29 | 29 |
30 enum WebContentsDelegateLogLevel { | 30 enum WebContentsDelegateLogLevel { |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 void VisibleSecurityStateChanged(content::WebContents* source) override; | 66 void VisibleSecurityStateChanged(content::WebContents* source) override; |
67 void ActivateContents(content::WebContents* contents) override; | 67 void ActivateContents(content::WebContents* contents) override; |
68 void LoadingStateChanged(content::WebContents* source, | 68 void LoadingStateChanged(content::WebContents* source, |
69 bool to_different_document) override; | 69 bool to_different_document) override; |
70 void LoadProgressChanged(content::WebContents* source, | 70 void LoadProgressChanged(content::WebContents* source, |
71 double load_progress) override; | 71 double load_progress) override; |
72 void RendererUnresponsive( | 72 void RendererUnresponsive( |
73 content::WebContents* source, | 73 content::WebContents* source, |
74 const content::WebContentsUnresponsiveState& unresponsive_state) override; | 74 const content::WebContentsUnresponsiveState& unresponsive_state) override; |
75 void RendererResponsive(content::WebContents* source) override; | 75 void RendererResponsive(content::WebContents* source) override; |
76 void WebContentsCreated( | 76 void WebContentsCreated(content::WebContents* source_contents, |
77 content::WebContents* source_contents, | 77 int opener_render_process_id, |
78 int opener_render_process_id, | 78 int opener_render_frame_id, |
79 int opener_render_frame_id, | 79 const std::string& frame_name, |
80 const std::string& frame_name, | 80 const GURL& target_url, |
81 const GURL& target_url, | 81 content::WebContents* new_contents) override; |
82 content::WebContents* new_contents, | |
83 const base::Optional<content::WebContents::CreateParams>& create_params) | |
84 override; | |
85 bool ShouldCreateWebContents( | 82 bool ShouldCreateWebContents( |
86 content::WebContents* web_contents, | 83 content::WebContents* web_contents, |
87 content::SiteInstance* source_site_instance, | 84 content::SiteInstance* source_site_instance, |
88 int32_t route_id, | 85 int32_t route_id, |
89 int32_t main_frame_route_id, | 86 int32_t main_frame_route_id, |
90 int32_t main_frame_widget_route_id, | 87 int32_t main_frame_widget_route_id, |
91 content::mojom::WindowContainerType window_container_type, | 88 content::mojom::WindowContainerType window_container_type, |
92 const GURL& opener_url, | 89 const GURL& opener_url, |
93 const std::string& frame_name, | 90 const std::string& frame_name, |
94 const GURL& target_url, | 91 const GURL& target_url, |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
135 // strong reference to that object as long as they want to receive callbacks | 132 // strong reference to that object as long as they want to receive callbacks |
136 // on it. Using a weak ref here allows it to be correctly GCed. | 133 // on it. Using a weak ref here allows it to be correctly GCed. |
137 JavaObjectWeakGlobalRef weak_java_delegate_; | 134 JavaObjectWeakGlobalRef weak_java_delegate_; |
138 | 135 |
139 std::unique_ptr<ValidationMessageBubbleAndroid> validation_message_bubble_; | 136 std::unique_ptr<ValidationMessageBubbleAndroid> validation_message_bubble_; |
140 }; | 137 }; |
141 | 138 |
142 } // namespace web_contents_delegate_android | 139 } // namespace web_contents_delegate_android |
143 | 140 |
144 #endif // COMPONENTS_WEB_CONTENTS_DELEGATE_ANDROID_WEB_CONTENTS_DELEGATE_ANDROI
D_H_ | 141 #endif // COMPONENTS_WEB_CONTENTS_DELEGATE_ANDROID_WEB_CONTENTS_DELEGATE_ANDROI
D_H_ |
OLD | NEW |