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 CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ |
6 #define CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ | 6 #define CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <set> | 9 #include <set> |
10 #include <string> | 10 #include <string> |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
45 struct ViewHostMsg_DateTimeDialogValue_Params; | 45 struct ViewHostMsg_DateTimeDialogValue_Params; |
46 struct ViewMsg_PostMessage_Params; | 46 struct ViewMsg_PostMessage_Params; |
47 | 47 |
48 namespace content { | 48 namespace content { |
49 class BrowserPluginEmbedder; | 49 class BrowserPluginEmbedder; |
50 class BrowserPluginGuest; | 50 class BrowserPluginGuest; |
51 class BrowserPluginGuestManager; | 51 class BrowserPluginGuestManager; |
52 class DateTimeChooserAndroid; | 52 class DateTimeChooserAndroid; |
53 class DownloadItem; | 53 class DownloadItem; |
54 class GeolocationDispatcherHost; | 54 class GeolocationDispatcherHost; |
55 class GeolocationServiceContext; | |
56 class InterstitialPageImpl; | 55 class InterstitialPageImpl; |
57 class JavaScriptDialogManager; | 56 class JavaScriptDialogManager; |
58 class ManifestManagerHost; | 57 class ManifestManagerHost; |
59 class MidiDispatcherHost; | 58 class MidiDispatcherHost; |
60 class PowerSaveBlocker; | 59 class PowerSaveBlocker; |
61 class RenderViewHost; | 60 class RenderViewHost; |
62 class RenderViewHostDelegateView; | 61 class RenderViewHostDelegateView; |
63 class RenderViewHostImpl; | 62 class RenderViewHostImpl; |
64 class RenderWidgetHostImpl; | 63 class RenderWidgetHostImpl; |
65 class SavePackage; | 64 class SavePackage; |
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
167 void DidGetResourceResponseStart( | 166 void DidGetResourceResponseStart( |
168 const ResourceRequestDetails& details); | 167 const ResourceRequestDetails& details); |
169 | 168 |
170 // A redirect was received while requesting a resource. | 169 // A redirect was received while requesting a resource. |
171 void DidGetRedirectForResourceRequest( | 170 void DidGetRedirectForResourceRequest( |
172 RenderViewHost* render_view_host, | 171 RenderViewHost* render_view_host, |
173 const ResourceRedirectDetails& details); | 172 const ResourceRedirectDetails& details); |
174 | 173 |
175 WebContentsView* GetView() const; | 174 WebContentsView* GetView() const; |
176 | 175 |
| 176 GeolocationDispatcherHost* geolocation_dispatcher_host() { |
| 177 return geolocation_dispatcher_host_.get(); |
| 178 } |
| 179 |
177 ScreenOrientationDispatcherHost* screen_orientation_dispatcher_host() { | 180 ScreenOrientationDispatcherHost* screen_orientation_dispatcher_host() { |
178 return screen_orientation_dispatcher_host_.get(); | 181 return screen_orientation_dispatcher_host_.get(); |
179 } | 182 } |
180 | 183 |
181 bool should_normally_be_visible() { return should_normally_be_visible_; } | 184 bool should_normally_be_visible() { return should_normally_be_visible_; } |
182 | 185 |
183 // Broadcasts the mode change to all frames. | 186 // Broadcasts the mode change to all frames. |
184 void SetAccessibilityMode(AccessibilityMode mode); | 187 void SetAccessibilityMode(AccessibilityMode mode); |
185 | 188 |
186 // Adds the given accessibility mode to the current accessibility mode | 189 // Adds the given accessibility mode to the current accessibility mode |
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
375 base::i18n::TextDirection title_direction) override; | 378 base::i18n::TextDirection title_direction) override; |
376 void UpdateEncoding(RenderFrameHost* render_frame_host, | 379 void UpdateEncoding(RenderFrameHost* render_frame_host, |
377 const std::string& encoding) override; | 380 const std::string& encoding) override; |
378 WebContents* GetAsWebContents() override; | 381 WebContents* GetAsWebContents() override; |
379 bool IsNeverVisible() override; | 382 bool IsNeverVisible() override; |
380 AccessibilityMode GetAccessibilityMode() const override; | 383 AccessibilityMode GetAccessibilityMode() const override; |
381 void AccessibilityEventReceived( | 384 void AccessibilityEventReceived( |
382 const std::vector<AXEventNotificationDetails>& details) override; | 385 const std::vector<AXEventNotificationDetails>& details) override; |
383 RenderFrameHost* GetGuestByInstanceID( | 386 RenderFrameHost* GetGuestByInstanceID( |
384 int browser_plugin_instance_id) override; | 387 int browser_plugin_instance_id) override; |
385 GeolocationServiceContext* GetGeolocationServiceContext() override; | |
386 #if defined(OS_WIN) | 388 #if defined(OS_WIN) |
387 gfx::NativeViewAccessible GetParentNativeViewAccessible() override; | 389 virtual gfx::NativeViewAccessible GetParentNativeViewAccessible() override; |
388 #endif | 390 #endif |
389 | 391 |
390 // RenderViewHostDelegate ---------------------------------------------------- | 392 // RenderViewHostDelegate ---------------------------------------------------- |
391 RenderViewHostDelegateView* GetDelegateView() override; | 393 RenderViewHostDelegateView* GetDelegateView() override; |
392 bool OnMessageReceived(RenderViewHost* render_view_host, | 394 bool OnMessageReceived(RenderViewHost* render_view_host, |
393 const IPC::Message& message) override; | 395 const IPC::Message& message) override; |
394 // RenderFrameHostDelegate has the same method, so list it there because this | 396 // RenderFrameHostDelegate has the same method, so list it there because this |
395 // interface is going away. | 397 // interface is going away. |
396 // virtual WebContents* GetAsWebContents() override; | 398 // virtual WebContents* GetAsWebContents() override; |
397 gfx::Rect GetRootWindowResizerRect() const override; | 399 gfx::Rect GetRootWindowResizerRect() const override; |
(...skipping 787 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1185 // Whether this WebContents is responsible for displaying a subframe in a | 1187 // Whether this WebContents is responsible for displaying a subframe in a |
1186 // different process from its parent page. | 1188 // different process from its parent page. |
1187 bool is_subframe_; | 1189 bool is_subframe_; |
1188 | 1190 |
1189 // Whether overscroll should be unconditionally disabled. | 1191 // Whether overscroll should be unconditionally disabled. |
1190 bool force_disable_overscroll_content_; | 1192 bool force_disable_overscroll_content_; |
1191 | 1193 |
1192 // Whether the last JavaScript dialog shown was suppressed. Used for testing. | 1194 // Whether the last JavaScript dialog shown was suppressed. Used for testing. |
1193 bool last_dialog_suppressed_; | 1195 bool last_dialog_suppressed_; |
1194 | 1196 |
1195 scoped_ptr<GeolocationServiceContext> geolocation_service_context_; | |
1196 | |
1197 scoped_ptr<GeolocationDispatcherHost> geolocation_dispatcher_host_; | 1197 scoped_ptr<GeolocationDispatcherHost> geolocation_dispatcher_host_; |
1198 | 1198 |
1199 scoped_ptr<MidiDispatcherHost> midi_dispatcher_host_; | 1199 scoped_ptr<MidiDispatcherHost> midi_dispatcher_host_; |
1200 | 1200 |
1201 scoped_ptr<ScreenOrientationDispatcherHost> | 1201 scoped_ptr<ScreenOrientationDispatcherHost> |
1202 screen_orientation_dispatcher_host_; | 1202 screen_orientation_dispatcher_host_; |
1203 | 1203 |
1204 scoped_ptr<ManifestManagerHost> manifest_manager_host_; | 1204 scoped_ptr<ManifestManagerHost> manifest_manager_host_; |
1205 | 1205 |
1206 // The accessibility mode for all frames. This is queried when each frame | 1206 // The accessibility mode for all frames. This is queried when each frame |
1207 // is created, and broadcast to all frames when it changes. | 1207 // is created, and broadcast to all frames when it changes. |
1208 AccessibilityMode accessibility_mode_; | 1208 AccessibilityMode accessibility_mode_; |
1209 | 1209 |
1210 // Monitors power levels for audio streams associated with this WebContents. | 1210 // Monitors power levels for audio streams associated with this WebContents. |
1211 AudioStreamMonitor audio_stream_monitor_; | 1211 AudioStreamMonitor audio_stream_monitor_; |
1212 | 1212 |
1213 // Created on-demand to mute all audio output from this WebContents. | 1213 // Created on-demand to mute all audio output from this WebContents. |
1214 scoped_ptr<WebContentsAudioMuter> audio_muter_; | 1214 scoped_ptr<WebContentsAudioMuter> audio_muter_; |
1215 | 1215 |
1216 base::WeakPtrFactory<WebContentsImpl> loading_weak_factory_; | 1216 base::WeakPtrFactory<WebContentsImpl> loading_weak_factory_; |
1217 | 1217 |
1218 DISALLOW_COPY_AND_ASSIGN(WebContentsImpl); | 1218 DISALLOW_COPY_AND_ASSIGN(WebContentsImpl); |
1219 }; | 1219 }; |
1220 | 1220 |
1221 } // namespace content | 1221 } // namespace content |
1222 | 1222 |
1223 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ | 1223 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_IMPL_H_ |
OLD | NEW |