| 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/renderer/renderer_webkitplatformsupport_impl.h" | 5 #include "content/renderer/renderer_webkitplatformsupport_impl.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/files/file_path.h" | 8 #include "base/files/file_path.h" |
| 9 #include "base/lazy_instance.h" | 9 #include "base/lazy_instance.h" |
| 10 #include "base/memory/shared_memory.h" | 10 #include "base/memory/shared_memory.h" |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 #include "content/common/gpu/client/context_provider_command_buffer.h" | 31 #include "content/common/gpu/client/context_provider_command_buffer.h" |
| 32 #include "content/common/gpu/client/gpu_channel_host.h" | 32 #include "content/common/gpu/client/gpu_channel_host.h" |
| 33 #include "content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.h" | 33 #include "content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.h" |
| 34 #include "content/common/gpu/gpu_process_launch_causes.h" | 34 #include "content/common/gpu/gpu_process_launch_causes.h" |
| 35 #include "content/common/mime_registry_messages.h" | 35 #include "content/common/mime_registry_messages.h" |
| 36 #include "content/common/screen_orientation_messages.h" | 36 #include "content/common/screen_orientation_messages.h" |
| 37 #include "content/common/view_messages.h" | 37 #include "content/common/view_messages.h" |
| 38 #include "content/public/common/content_switches.h" | 38 #include "content/public/common/content_switches.h" |
| 39 #include "content/public/common/webplugininfo.h" | 39 #include "content/public/common/webplugininfo.h" |
| 40 #include "content/public/renderer/content_renderer_client.h" | 40 #include "content/public/renderer/content_renderer_client.h" |
| 41 #include "content/renderer/battery_status/battery_status_dispatcher.h" |
| 41 #include "content/renderer/device_sensors/device_motion_event_pump.h" | 42 #include "content/renderer/device_sensors/device_motion_event_pump.h" |
| 42 #include "content/renderer/device_sensors/device_orientation_event_pump.h" | 43 #include "content/renderer/device_sensors/device_orientation_event_pump.h" |
| 43 #include "content/renderer/dom_storage/webstoragenamespace_impl.h" | 44 #include "content/renderer/dom_storage/webstoragenamespace_impl.h" |
| 44 #include "content/renderer/gamepad_shared_memory_reader.h" | 45 #include "content/renderer/gamepad_shared_memory_reader.h" |
| 45 #include "content/renderer/media/audio_decoder.h" | 46 #include "content/renderer/media/audio_decoder.h" |
| 46 #include "content/renderer/media/crypto/key_systems.h" | 47 #include "content/renderer/media/crypto/key_systems.h" |
| 47 #include "content/renderer/media/media_stream_dependency_factory.h" | 48 #include "content/renderer/media/media_stream_dependency_factory.h" |
| 48 #include "content/renderer/media/renderer_webaudiodevice_impl.h" | 49 #include "content/renderer/media/renderer_webaudiodevice_impl.h" |
| 49 #include "content/renderer/media/renderer_webmidiaccessor_impl.h" | 50 #include "content/renderer/media/renderer_webmidiaccessor_impl.h" |
| 50 #include "content/renderer/media/webcontentdecryptionmodule_impl.h" | 51 #include "content/renderer/media/webcontentdecryptionmodule_impl.h" |
| 51 #include "content/renderer/render_thread_impl.h" | 52 #include "content/renderer/render_thread_impl.h" |
| 52 #include "content/renderer/renderer_clipboard_client.h" | 53 #include "content/renderer/renderer_clipboard_client.h" |
| 53 #include "content/renderer/screen_orientation/screen_orientation_dispatcher.h" | 54 #include "content/renderer/screen_orientation/screen_orientation_dispatcher.h" |
| 54 #include "content/renderer/webclipboard_impl.h" | 55 #include "content/renderer/webclipboard_impl.h" |
| 55 #include "content/renderer/webgraphicscontext3d_provider_impl.h" | 56 #include "content/renderer/webgraphicscontext3d_provider_impl.h" |
| 56 #include "content/renderer/webpublicsuffixlist_impl.h" | 57 #include "content/renderer/webpublicsuffixlist_impl.h" |
| 57 #include "gpu/config/gpu_info.h" | 58 #include "gpu/config/gpu_info.h" |
| 58 #include "ipc/ipc_sync_message_filter.h" | 59 #include "ipc/ipc_sync_message_filter.h" |
| 59 #include "media/audio/audio_output_device.h" | 60 #include "media/audio/audio_output_device.h" |
| 60 #include "media/base/audio_hardware_config.h" | 61 #include "media/base/audio_hardware_config.h" |
| 61 #include "media/filters/stream_parser_factory.h" | 62 #include "media/filters/stream_parser_factory.h" |
| 62 #include "net/base/mime_util.h" | 63 #include "net/base/mime_util.h" |
| 63 #include "net/base/net_util.h" | 64 #include "net/base/net_util.h" |
| 65 #include "third_party/WebKit/public/platform/WebBatteryStatusListener.h" |
| 64 #include "third_party/WebKit/public/platform/WebBlobRegistry.h" | 66 #include "third_party/WebKit/public/platform/WebBlobRegistry.h" |
| 65 #include "third_party/WebKit/public/platform/WebDeviceMotionListener.h" | 67 #include "third_party/WebKit/public/platform/WebDeviceMotionListener.h" |
| 66 #include "third_party/WebKit/public/platform/WebDeviceOrientationListener.h" | 68 #include "third_party/WebKit/public/platform/WebDeviceOrientationListener.h" |
| 67 #include "third_party/WebKit/public/platform/WebFileInfo.h" | 69 #include "third_party/WebKit/public/platform/WebFileInfo.h" |
| 68 #include "third_party/WebKit/public/platform/WebGamepads.h" | 70 #include "third_party/WebKit/public/platform/WebGamepads.h" |
| 69 #include "third_party/WebKit/public/platform/WebMediaStreamCenter.h" | 71 #include "third_party/WebKit/public/platform/WebMediaStreamCenter.h" |
| 70 #include "third_party/WebKit/public/platform/WebMediaStreamCenterClient.h" | 72 #include "third_party/WebKit/public/platform/WebMediaStreamCenterClient.h" |
| 71 #include "third_party/WebKit/public/platform/WebPluginListBuilder.h" | 73 #include "third_party/WebKit/public/platform/WebPluginListBuilder.h" |
| 72 #include "third_party/WebKit/public/platform/WebScreenOrientationListener.h" | 74 #include "third_party/WebKit/public/platform/WebScreenOrientationListener.h" |
| 73 #include "third_party/WebKit/public/platform/WebURL.h" | 75 #include "third_party/WebKit/public/platform/WebURL.h" |
| (...skipping 1101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1175 if (!thread_safe_sender_.get() || !quota_message_filter_.get()) | 1177 if (!thread_safe_sender_.get() || !quota_message_filter_.get()) |
| 1176 return; | 1178 return; |
| 1177 QuotaDispatcher::ThreadSpecificInstance( | 1179 QuotaDispatcher::ThreadSpecificInstance( |
| 1178 thread_safe_sender_.get(), | 1180 thread_safe_sender_.get(), |
| 1179 quota_message_filter_.get())->QueryStorageUsageAndQuota( | 1181 quota_message_filter_.get())->QueryStorageUsageAndQuota( |
| 1180 storage_partition, | 1182 storage_partition, |
| 1181 static_cast<quota::StorageType>(type), | 1183 static_cast<quota::StorageType>(type), |
| 1182 QuotaDispatcher::CreateWebStorageQuotaCallbacksWrapper(callbacks)); | 1184 QuotaDispatcher::CreateWebStorageQuotaCallbacksWrapper(callbacks)); |
| 1183 } | 1185 } |
| 1184 | 1186 |
| 1187 //------------------------------------------------------------------------------ |
| 1188 |
| 1189 void RendererWebKitPlatformSupportImpl::setBatteryStatusListener( |
| 1190 blink::WebBatteryStatusListener* listener) { |
| 1191 if (!battery_status_dispatcher_) { |
| 1192 battery_status_dispatcher_.reset( |
| 1193 new BatteryStatusDispatcher(RenderThreadImpl::current())); |
| 1194 } |
| 1195 battery_status_dispatcher_->SetListener(listener); |
| 1196 } |
| 1197 |
| 1185 } // namespace content | 1198 } // namespace content |
| OLD | NEW |