| 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 // 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 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 86 #include "content/browser/renderer_host/pepper/pepper_message_filter.h" | 86 #include "content/browser/renderer_host/pepper/pepper_message_filter.h" |
| 87 #include "content/browser/renderer_host/pepper/pepper_renderer_connection.h" | 87 #include "content/browser/renderer_host/pepper/pepper_renderer_connection.h" |
| 88 #include "content/browser/renderer_host/render_frame_message_filter.h" | 88 #include "content/browser/renderer_host/render_frame_message_filter.h" |
| 89 #include "content/browser/renderer_host/render_message_filter.h" | 89 #include "content/browser/renderer_host/render_message_filter.h" |
| 90 #include "content/browser/renderer_host/render_view_host_delegate.h" | 90 #include "content/browser/renderer_host/render_view_host_delegate.h" |
| 91 #include "content/browser/renderer_host/render_view_host_impl.h" | 91 #include "content/browser/renderer_host/render_view_host_impl.h" |
| 92 #include "content/browser/renderer_host/render_widget_helper.h" | 92 #include "content/browser/renderer_host/render_widget_helper.h" |
| 93 #include "content/browser/renderer_host/render_widget_host_impl.h" | 93 #include "content/browser/renderer_host/render_widget_host_impl.h" |
| 94 #include "content/browser/renderer_host/socket_stream_dispatcher_host.h" | 94 #include "content/browser/renderer_host/socket_stream_dispatcher_host.h" |
| 95 #include "content/browser/renderer_host/text_input_client_message_filter.h" | 95 #include "content/browser/renderer_host/text_input_client_message_filter.h" |
| 96 #include "content/browser/renderer_host/websocket_dispatcher_host.h" |
| 96 #include "content/browser/resolve_proxy_msg_helper.h" | 97 #include "content/browser/resolve_proxy_msg_helper.h" |
| 97 #include "content/browser/service_worker/service_worker_context.h" | 98 #include "content/browser/service_worker/service_worker_context.h" |
| 98 #include "content/browser/service_worker/service_worker_dispatcher_host.h" | 99 #include "content/browser/service_worker/service_worker_dispatcher_host.h" |
| 99 #include "content/browser/speech/input_tag_speech_dispatcher_host.h" | 100 #include "content/browser/speech/input_tag_speech_dispatcher_host.h" |
| 100 #include "content/browser/speech/speech_recognition_dispatcher_host.h" | 101 #include "content/browser/speech/speech_recognition_dispatcher_host.h" |
| 101 #include "content/browser/storage_partition_impl.h" | 102 #include "content/browser/storage_partition_impl.h" |
| 102 #include "content/browser/streams/stream_context.h" | 103 #include "content/browser/streams/stream_context.h" |
| 103 #include "content/browser/tracing/trace_message_filter.h" | 104 #include "content/browser/tracing/trace_message_filter.h" |
| 104 #include "content/browser/webui/web_ui_controller_factory_registry.h" | 105 #include "content/browser/webui/web_ui_controller_factory_registry.h" |
| 105 #include "content/browser/worker_host/worker_message_filter.h" | 106 #include "content/browser/worker_host/worker_message_filter.h" |
| (...skipping 558 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 664 SocketStreamDispatcherHost::GetRequestContextCallback | 665 SocketStreamDispatcherHost::GetRequestContextCallback |
| 665 request_context_callback( | 666 request_context_callback( |
| 666 base::Bind(&GetRequestContext, request_context, | 667 base::Bind(&GetRequestContext, request_context, |
| 667 media_request_context)); | 668 media_request_context)); |
| 668 | 669 |
| 669 SocketStreamDispatcherHost* socket_stream_dispatcher_host = | 670 SocketStreamDispatcherHost* socket_stream_dispatcher_host = |
| 670 new SocketStreamDispatcherHost( | 671 new SocketStreamDispatcherHost( |
| 671 GetID(), request_context_callback, resource_context); | 672 GetID(), request_context_callback, resource_context); |
| 672 AddFilter(socket_stream_dispatcher_host); | 673 AddFilter(socket_stream_dispatcher_host); |
| 673 | 674 |
| 675 WebSocketDispatcherHost::GetRequestContextCallback |
| 676 websocket_request_context_callback( |
| 677 base::Bind(&GetRequestContext, request_context, |
| 678 media_request_context, ResourceType::SUB_RESOURCE)); |
| 679 |
| 680 AddFilter(new WebSocketDispatcherHost(websocket_request_context_callback)); |
| 681 |
| 674 message_port_message_filter_ = new MessagePortMessageFilter( | 682 message_port_message_filter_ = new MessagePortMessageFilter( |
| 675 base::Bind(&RenderWidgetHelper::GetNextRoutingID, | 683 base::Bind(&RenderWidgetHelper::GetNextRoutingID, |
| 676 base::Unretained(widget_helper_.get()))); | 684 base::Unretained(widget_helper_.get()))); |
| 677 AddFilter(message_port_message_filter_); | 685 AddFilter(message_port_message_filter_); |
| 678 | 686 |
| 679 AddFilter(new WorkerMessageFilter( | 687 AddFilter(new WorkerMessageFilter( |
| 680 GetID(), | 688 GetID(), |
| 681 resource_context, | 689 resource_context, |
| 682 WorkerStoragePartition( | 690 WorkerStoragePartition( |
| 683 storage_partition_impl_->GetURLRequestContext(), | 691 storage_partition_impl_->GetURLRequestContext(), |
| (...skipping 1129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1813 // Skip widgets in other processes. | 1821 // Skip widgets in other processes. |
| 1814 if (widget->GetProcess()->GetID() != GetID()) | 1822 if (widget->GetProcess()->GetID() != GetID()) |
| 1815 continue; | 1823 continue; |
| 1816 | 1824 |
| 1817 RenderViewHost* rvh = RenderViewHost::From(widget); | 1825 RenderViewHost* rvh = RenderViewHost::From(widget); |
| 1818 rvh->UpdateWebkitPreferences(rvh->GetWebkitPreferences()); | 1826 rvh->UpdateWebkitPreferences(rvh->GetWebkitPreferences()); |
| 1819 } | 1827 } |
| 1820 } | 1828 } |
| 1821 | 1829 |
| 1822 } // namespace content | 1830 } // namespace content |
| OLD | NEW |