| 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 "content/browser/web_contents/web_contents_impl.h" | 5 #include "content/browser/web_contents/web_contents_impl.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/debug/trace_event.h" | 10 #include "base/debug/trace_event.h" |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 #include "content/browser/geolocation/geolocation_dispatcher_host.h" | 38 #include "content/browser/geolocation/geolocation_dispatcher_host.h" |
| 39 #include "content/browser/geolocation/geolocation_service_context.h" | 39 #include "content/browser/geolocation/geolocation_service_context.h" |
| 40 #include "content/browser/host_zoom_map_impl.h" | 40 #include "content/browser/host_zoom_map_impl.h" |
| 41 #include "content/browser/loader/resource_dispatcher_host_impl.h" | 41 #include "content/browser/loader/resource_dispatcher_host_impl.h" |
| 42 #include "content/browser/manifest/manifest_manager_host.h" | 42 #include "content/browser/manifest/manifest_manager_host.h" |
| 43 #include "content/browser/media/audio_stream_monitor.h" | 43 #include "content/browser/media/audio_stream_monitor.h" |
| 44 #include "content/browser/media/capture/web_contents_audio_muter.h" | 44 #include "content/browser/media/capture/web_contents_audio_muter.h" |
| 45 #include "content/browser/media/midi_dispatcher_host.h" | 45 #include "content/browser/media/midi_dispatcher_host.h" |
| 46 #include "content/browser/message_port_message_filter.h" | 46 #include "content/browser/message_port_message_filter.h" |
| 47 #include "content/browser/message_port_service.h" | 47 #include "content/browser/message_port_service.h" |
| 48 #include "content/browser/plugin_content_origin_whitelist.h" |
| 48 #include "content/browser/power_save_blocker_impl.h" | 49 #include "content/browser/power_save_blocker_impl.h" |
| 49 #include "content/browser/renderer_host/render_process_host_impl.h" | 50 #include "content/browser/renderer_host/render_process_host_impl.h" |
| 50 #include "content/browser/renderer_host/render_view_host_delegate_view.h" | 51 #include "content/browser/renderer_host/render_view_host_delegate_view.h" |
| 51 #include "content/browser/renderer_host/render_view_host_impl.h" | 52 #include "content/browser/renderer_host/render_view_host_impl.h" |
| 52 #include "content/browser/renderer_host/render_widget_host_impl.h" | 53 #include "content/browser/renderer_host/render_widget_host_impl.h" |
| 53 #include "content/browser/renderer_host/render_widget_host_view_base.h" | 54 #include "content/browser/renderer_host/render_widget_host_view_base.h" |
| 54 #include "content/browser/screen_orientation/screen_orientation_dispatcher_host_
impl.h" | 55 #include "content/browser/screen_orientation/screen_orientation_dispatcher_host_
impl.h" |
| 55 #include "content/browser/site_instance_impl.h" | 56 #include "content/browser/site_instance_impl.h" |
| 56 #include "content/browser/web_contents/web_contents_view_guest.h" | 57 #include "content/browser/web_contents/web_contents_view_guest.h" |
| 57 #include "content/browser/webui/generic_handler.h" | 58 #include "content/browser/webui/generic_handler.h" |
| (...skipping 1114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1172 CHECK(render_view_host_delegate_view_); | 1173 CHECK(render_view_host_delegate_view_); |
| 1173 CHECK(view_.get()); | 1174 CHECK(view_.get()); |
| 1174 | 1175 |
| 1175 gfx::Size initial_size = params.initial_size; | 1176 gfx::Size initial_size = params.initial_size; |
| 1176 view_->CreateView(initial_size, params.context); | 1177 view_->CreateView(initial_size, params.context); |
| 1177 | 1178 |
| 1178 // Listen for whether our opener gets destroyed. | 1179 // Listen for whether our opener gets destroyed. |
| 1179 if (opener_) | 1180 if (opener_) |
| 1180 AddDestructionObserver(opener_); | 1181 AddDestructionObserver(opener_); |
| 1181 | 1182 |
| 1183 #if defined(ENABLE_PLUGINS) |
| 1184 plugin_content_origin_whitelist_.reset( |
| 1185 new PluginContentOriginWhitelist(this)); |
| 1186 #endif |
| 1187 |
| 1182 registrar_.Add(this, | 1188 registrar_.Add(this, |
| 1183 NOTIFICATION_RENDER_WIDGET_HOST_DESTROYED, | 1189 NOTIFICATION_RENDER_WIDGET_HOST_DESTROYED, |
| 1184 NotificationService::AllBrowserContextsAndSources()); | 1190 NotificationService::AllBrowserContextsAndSources()); |
| 1185 | 1191 |
| 1186 geolocation_dispatcher_host_.reset(new GeolocationDispatcherHost(this)); | 1192 geolocation_dispatcher_host_.reset(new GeolocationDispatcherHost(this)); |
| 1187 midi_dispatcher_host_.reset(new MidiDispatcherHost(this)); | 1193 midi_dispatcher_host_.reset(new MidiDispatcherHost(this)); |
| 1188 | 1194 |
| 1189 screen_orientation_dispatcher_host_.reset( | 1195 screen_orientation_dispatcher_host_.reset( |
| 1190 new ScreenOrientationDispatcherHostImpl(this)); | 1196 new ScreenOrientationDispatcherHostImpl(this)); |
| 1191 | 1197 |
| (...skipping 3137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4329 node->render_manager()->ResumeResponseDeferredAtStart(); | 4335 node->render_manager()->ResumeResponseDeferredAtStart(); |
| 4330 } | 4336 } |
| 4331 | 4337 |
| 4332 void WebContentsImpl::SetForceDisableOverscrollContent(bool force_disable) { | 4338 void WebContentsImpl::SetForceDisableOverscrollContent(bool force_disable) { |
| 4333 force_disable_overscroll_content_ = force_disable; | 4339 force_disable_overscroll_content_ = force_disable; |
| 4334 if (view_) | 4340 if (view_) |
| 4335 view_->SetOverscrollControllerEnabled(CanOverscrollContent()); | 4341 view_->SetOverscrollControllerEnabled(CanOverscrollContent()); |
| 4336 } | 4342 } |
| 4337 | 4343 |
| 4338 } // namespace content | 4344 } // namespace content |
| OLD | NEW |