| 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_blink_platform_impl.h" | 5 #include "content/renderer/renderer_blink_platform_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/files/file_path.h" | 10 #include "base/files/file_path.h" |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 50 #include "content/public/common/content_switches.h" | 50 #include "content/public/common/content_switches.h" |
| 51 #include "content/public/common/service_registry.h" | 51 #include "content/public/common/service_registry.h" |
| 52 #include "content/public/common/webplugininfo.h" | 52 #include "content/public/common/webplugininfo.h" |
| 53 #include "content/public/renderer/content_renderer_client.h" | 53 #include "content/public/renderer/content_renderer_client.h" |
| 54 #include "content/public/renderer/media_stream_api.h" | 54 #include "content/public/renderer/media_stream_api.h" |
| 55 #include "content/renderer/cache_storage/webserviceworkercachestorage_impl.h" | 55 #include "content/renderer/cache_storage/webserviceworkercachestorage_impl.h" |
| 56 #include "content/renderer/device_sensors/device_light_event_pump.h" | 56 #include "content/renderer/device_sensors/device_light_event_pump.h" |
| 57 #include "content/renderer/device_sensors/device_motion_event_pump.h" | 57 #include "content/renderer/device_sensors/device_motion_event_pump.h" |
| 58 #include "content/renderer/device_sensors/device_orientation_absolute_event_pump
.h" | 58 #include "content/renderer/device_sensors/device_orientation_absolute_event_pump
.h" |
| 59 #include "content/renderer/device_sensors/device_orientation_event_pump.h" | 59 #include "content/renderer/device_sensors/device_orientation_event_pump.h" |
| 60 #include "content/renderer/dom_storage/local_storage_cached_areas.h" |
| 60 #include "content/renderer/dom_storage/local_storage_namespace.h" | 61 #include "content/renderer/dom_storage/local_storage_namespace.h" |
| 61 #include "content/renderer/dom_storage/webstoragenamespace_impl.h" | 62 #include "content/renderer/dom_storage/webstoragenamespace_impl.h" |
| 62 #include "content/renderer/gamepad_shared_memory_reader.h" | 63 #include "content/renderer/gamepad_shared_memory_reader.h" |
| 63 #include "content/renderer/media/audio_decoder.h" | 64 #include "content/renderer/media/audio_decoder.h" |
| 64 #include "content/renderer/media/canvas_capture_handler.h" | 65 #include "content/renderer/media/canvas_capture_handler.h" |
| 65 #include "content/renderer/media/html_video_element_capturer_source.h" | 66 #include "content/renderer/media/html_video_element_capturer_source.h" |
| 66 #include "content/renderer/media/media_recorder_handler.h" | 67 #include "content/renderer/media/media_recorder_handler.h" |
| 67 #include "content/renderer/media/renderer_webaudiodevice_impl.h" | 68 #include "content/renderer/media/renderer_webaudiodevice_impl.h" |
| 68 #include "content/renderer/media/renderer_webmidiaccessor_impl.h" | 69 #include "content/renderer/media/renderer_webmidiaccessor_impl.h" |
| 69 #include "content/renderer/media/rtc_certificate_generator.h" | 70 #include "content/renderer/media/rtc_certificate_generator.h" |
| (...skipping 337 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 407 } | 408 } |
| 408 | 409 |
| 409 RenderThread* thread = RenderThread::Get(); | 410 RenderThread* thread = RenderThread::Get(); |
| 410 if (thread) // NULL in unittests. | 411 if (thread) // NULL in unittests. |
| 411 thread->Send(new RenderProcessHostMsg_SuddenTerminationChanged(enabled)); | 412 thread->Send(new RenderProcessHostMsg_SuddenTerminationChanged(enabled)); |
| 412 } | 413 } |
| 413 | 414 |
| 414 WebStorageNamespace* RendererBlinkPlatformImpl::createLocalStorageNamespace() { | 415 WebStorageNamespace* RendererBlinkPlatformImpl::createLocalStorageNamespace() { |
| 415 if (base::CommandLine::ForCurrentProcess()->HasSwitch( | 416 if (base::CommandLine::ForCurrentProcess()->HasSwitch( |
| 416 switches::kMojoLocalStorage)) { | 417 switches::kMojoLocalStorage)) { |
| 417 return new LocalStorageNamespace( | 418 if (!local_storage_cached_areas_) { |
| 418 RenderThreadImpl::current()->GetStoragePartitionService()); | 419 local_storage_cached_areas_.reset(new LocalStorageCachedAreas( |
| 420 RenderThreadImpl::current()->GetStoragePartitionService())); |
| 421 } |
| 422 return new LocalStorageNamespace(local_storage_cached_areas_.get()); |
| 419 } | 423 } |
| 424 |
| 420 return new WebStorageNamespaceImpl(); | 425 return new WebStorageNamespaceImpl(); |
| 421 } | 426 } |
| 422 | 427 |
| 423 | 428 |
| 424 //------------------------------------------------------------------------------ | 429 //------------------------------------------------------------------------------ |
| 425 | 430 |
| 426 WebIDBFactory* RendererBlinkPlatformImpl::idbFactory() { | 431 WebIDBFactory* RendererBlinkPlatformImpl::idbFactory() { |
| 427 return web_idb_factory_.get(); | 432 return web_idb_factory_.get(); |
| 428 } | 433 } |
| 429 | 434 |
| (...skipping 830 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1260 } | 1265 } |
| 1261 | 1266 |
| 1262 //------------------------------------------------------------------------------ | 1267 //------------------------------------------------------------------------------ |
| 1263 | 1268 |
| 1264 blink::WebTrialTokenValidator* | 1269 blink::WebTrialTokenValidator* |
| 1265 RendererBlinkPlatformImpl::trialTokenValidator() { | 1270 RendererBlinkPlatformImpl::trialTokenValidator() { |
| 1266 return &trial_token_validator_; | 1271 return &trial_token_validator_; |
| 1267 } | 1272 } |
| 1268 | 1273 |
| 1269 } // namespace content | 1274 } // namespace content |
| OLD | NEW |