| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 // Represents the browser side of the browser <--> renderer communication | 5 // Represents the browser side of the browser <--> renderer communication |
| 6 // channel. There will be one RenderProcessHost per renderer process. | 6 // channel. There will be one RenderProcessHost per renderer process. |
| 7 | 7 |
| 8 #include "content/browser/renderer_host/render_process_host_impl.h" | 8 #include "content/browser/renderer_host/render_process_host_impl.h" |
| 9 | 9 |
| 10 #include <algorithm> | 10 #include <algorithm> |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 68 #include "content/browser/dom_storage/dom_storage_context_wrapper.h" | 68 #include "content/browser/dom_storage/dom_storage_context_wrapper.h" |
| 69 #include "content/browser/dom_storage/dom_storage_message_filter.h" | 69 #include "content/browser/dom_storage/dom_storage_message_filter.h" |
| 70 #include "content/browser/fileapi/fileapi_message_filter.h" | 70 #include "content/browser/fileapi/fileapi_message_filter.h" |
| 71 #include "content/browser/frame_host/render_frame_message_filter.h" | 71 #include "content/browser/frame_host/render_frame_message_filter.h" |
| 72 #include "content/browser/gpu/browser_gpu_memory_buffer_manager.h" | 72 #include "content/browser/gpu/browser_gpu_memory_buffer_manager.h" |
| 73 #include "content/browser/gpu/compositor_util.h" | 73 #include "content/browser/gpu/compositor_util.h" |
| 74 #include "content/browser/gpu/gpu_data_manager_impl.h" | 74 #include "content/browser/gpu/gpu_data_manager_impl.h" |
| 75 #include "content/browser/gpu/gpu_process_host.h" | 75 #include "content/browser/gpu/gpu_process_host.h" |
| 76 #include "content/browser/gpu/shader_disk_cache.h" | 76 #include "content/browser/gpu/shader_disk_cache.h" |
| 77 #include "content/browser/histogram_message_filter.h" | 77 #include "content/browser/histogram_message_filter.h" |
| 78 #include "content/browser/indexed_db/database_factory_impl.h" |
| 78 #include "content/browser/indexed_db/indexed_db_context_impl.h" | 79 #include "content/browser/indexed_db/indexed_db_context_impl.h" |
| 79 #include "content/browser/indexed_db/indexed_db_dispatcher_host.h" | 80 #include "content/browser/indexed_db/indexed_db_dispatcher_host.h" |
| 80 #include "content/browser/loader/resource_message_filter.h" | 81 #include "content/browser/loader/resource_message_filter.h" |
| 81 #include "content/browser/loader/resource_scheduler_filter.h" | 82 #include "content/browser/loader/resource_scheduler_filter.h" |
| 82 #include "content/browser/loader/url_loader_factory_impl.h" | 83 #include "content/browser/loader/url_loader_factory_impl.h" |
| 83 #include "content/browser/media/capture/audio_mirroring_manager.h" | 84 #include "content/browser/media/capture/audio_mirroring_manager.h" |
| 84 #include "content/browser/media/capture/image_capture_impl.h" | 85 #include "content/browser/media/capture/image_capture_impl.h" |
| 85 #include "content/browser/media/media_internals.h" | 86 #include "content/browser/media/media_internals.h" |
| 86 #include "content/browser/media/midi_host.h" | 87 #include "content/browser/media/midi_host.h" |
| 87 #include "content/browser/memory/memory_message_filter.h" | 88 #include "content/browser/memory/memory_message_filter.h" |
| (...skipping 999 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1087 browser_context->GetResourceContext()->GetMediaDeviceIDSalt()); | 1088 browser_context->GetResourceContext()->GetMediaDeviceIDSalt()); |
| 1088 AddFilter(audio_renderer_host_.get()); | 1089 AddFilter(audio_renderer_host_.get()); |
| 1089 AddFilter( | 1090 AddFilter( |
| 1090 new MidiHost(GetID(), BrowserMainLoop::GetInstance()->midi_manager())); | 1091 new MidiHost(GetID(), BrowserMainLoop::GetInstance()->midi_manager())); |
| 1091 AddFilter(new VideoCaptureHost(media_stream_manager)); | 1092 AddFilter(new VideoCaptureHost(media_stream_manager)); |
| 1092 AddFilter(new AppCacheDispatcherHost( | 1093 AddFilter(new AppCacheDispatcherHost( |
| 1093 storage_partition_impl_->GetAppCacheService(), GetID())); | 1094 storage_partition_impl_->GetAppCacheService(), GetID())); |
| 1094 AddFilter(new ClipboardMessageFilter(blob_storage_context)); | 1095 AddFilter(new ClipboardMessageFilter(blob_storage_context)); |
| 1095 AddFilter(new DOMStorageMessageFilter( | 1096 AddFilter(new DOMStorageMessageFilter( |
| 1096 storage_partition_impl_->GetDOMStorageContext())); | 1097 storage_partition_impl_->GetDOMStorageContext())); |
| 1097 AddFilter(new IndexedDBDispatcherHost( | 1098 |
| 1099 idb_dispatcher_host_ = new IndexedDBDispatcherHost( |
| 1098 GetID(), storage_partition_impl_->GetURLRequestContext(), | 1100 GetID(), storage_partition_impl_->GetURLRequestContext(), |
| 1099 storage_partition_impl_->GetIndexedDBContext(), | 1101 storage_partition_impl_->GetIndexedDBContext(), |
| 1100 blob_storage_context.get())); | 1102 blob_storage_context.get()); |
| 1103 idb_database_factory_.reset( |
| 1104 new DatabaseFactoryImpl(storage_partition_impl_->GetURLRequestContext(), |
| 1105 storage_partition_impl_->GetIndexedDBContext(), |
| 1106 GetID(), idb_dispatcher_host_)); |
| 1107 AddFilter(idb_dispatcher_host_.get()); |
| 1101 | 1108 |
| 1102 #if defined(ENABLE_WEBRTC) | 1109 #if defined(ENABLE_WEBRTC) |
| 1103 peer_connection_tracker_host_ = new PeerConnectionTrackerHost( | 1110 peer_connection_tracker_host_ = new PeerConnectionTrackerHost( |
| 1104 GetID(), webrtc_eventlog_host_.GetWeakPtr()); | 1111 GetID(), webrtc_eventlog_host_.GetWeakPtr()); |
| 1105 AddFilter(peer_connection_tracker_host_.get()); | 1112 AddFilter(peer_connection_tracker_host_.get()); |
| 1106 AddFilter(new MediaStreamDispatcherHost( | 1113 AddFilter(new MediaStreamDispatcherHost( |
| 1107 GetID(), browser_context->GetResourceContext()->GetMediaDeviceIDSalt(), | 1114 GetID(), browser_context->GetResourceContext()->GetMediaDeviceIDSalt(), |
| 1108 media_stream_manager)); | 1115 media_stream_manager)); |
| 1109 AddFilter(new MediaStreamTrackMetricsHost()); | 1116 AddFilter(new MediaStreamTrackMetricsHost()); |
| 1110 #endif | 1117 #endif |
| (...skipping 1854 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2965 LOG(ERROR) << "Terminating render process for bad Mojo message: " << error; | 2972 LOG(ERROR) << "Terminating render process for bad Mojo message: " << error; |
| 2966 | 2973 |
| 2967 // The ReceivedBadMessage call below will trigger a DumpWithoutCrashing. Alias | 2974 // The ReceivedBadMessage call below will trigger a DumpWithoutCrashing. Alias |
| 2968 // enough information here so that we can determine what the bad message was. | 2975 // enough information here so that we can determine what the bad message was. |
| 2969 base::debug::Alias(&error); | 2976 base::debug::Alias(&error); |
| 2970 bad_message::ReceivedBadMessage(process.get(), | 2977 bad_message::ReceivedBadMessage(process.get(), |
| 2971 bad_message::RPH_MOJO_PROCESS_ERROR); | 2978 bad_message::RPH_MOJO_PROCESS_ERROR); |
| 2972 } | 2979 } |
| 2973 | 2980 |
| 2974 } // namespace content | 2981 } // namespace content |
| OLD | NEW |