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 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
96 #include "content/browser/renderer_host/websocket_dispatcher_host.h" | 96 #include "content/browser/renderer_host/websocket_dispatcher_host.h" |
97 #include "content/browser/resolve_proxy_msg_helper.h" | 97 #include "content/browser/resolve_proxy_msg_helper.h" |
98 #include "content/browser/screen_orientation/screen_orientation_dispatcher_host.
h" | 98 #include "content/browser/screen_orientation/screen_orientation_dispatcher_host.
h" |
99 #include "content/browser/service_worker/service_worker_context_wrapper.h" | 99 #include "content/browser/service_worker/service_worker_context_wrapper.h" |
100 #include "content/browser/service_worker/service_worker_dispatcher_host.h" | 100 #include "content/browser/service_worker/service_worker_dispatcher_host.h" |
101 #include "content/browser/shared_worker/shared_worker_message_filter.h" | 101 #include "content/browser/shared_worker/shared_worker_message_filter.h" |
102 #include "content/browser/speech/speech_recognition_dispatcher_host.h" | 102 #include "content/browser/speech/speech_recognition_dispatcher_host.h" |
103 #include "content/browser/storage_partition_impl.h" | 103 #include "content/browser/storage_partition_impl.h" |
104 #include "content/browser/streams/stream_context.h" | 104 #include "content/browser/streams/stream_context.h" |
105 #include "content/browser/tracing/trace_message_filter.h" | 105 #include "content/browser/tracing/trace_message_filter.h" |
| 106 #include "content/browser/transition_request_message_filter.h" |
106 #include "content/browser/vibration/vibration_message_filter.h" | 107 #include "content/browser/vibration/vibration_message_filter.h" |
107 #include "content/browser/webui/web_ui_controller_factory_registry.h" | 108 #include "content/browser/webui/web_ui_controller_factory_registry.h" |
108 #include "content/browser/worker_host/worker_message_filter.h" | 109 #include "content/browser/worker_host/worker_message_filter.h" |
109 #include "content/browser/worker_host/worker_storage_partition.h" | 110 #include "content/browser/worker_host/worker_storage_partition.h" |
110 #include "content/common/child_process_host_impl.h" | 111 #include "content/common/child_process_host_impl.h" |
111 #include "content/common/child_process_messages.h" | 112 #include "content/common/child_process_messages.h" |
112 #include "content/common/content_switches_internal.h" | 113 #include "content/common/content_switches_internal.h" |
113 #include "content/common/gpu/gpu_messages.h" | 114 #include "content/common/gpu/gpu_messages.h" |
114 #include "content/common/mojo/mojo_messages.h" | 115 #include "content/common/mojo/mojo_messages.h" |
115 #include "content/common/resource_messages.h" | 116 #include "content/common/resource_messages.h" |
(...skipping 711 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
827 AddFilter(new HistogramMessageFilter()); | 828 AddFilter(new HistogramMessageFilter()); |
828 #if defined(USE_TCMALLOC) && (defined(OS_LINUX) || defined(OS_ANDROID)) | 829 #if defined(USE_TCMALLOC) && (defined(OS_LINUX) || defined(OS_ANDROID)) |
829 if (CommandLine::ForCurrentProcess()->HasSwitch( | 830 if (CommandLine::ForCurrentProcess()->HasSwitch( |
830 switches::kEnableMemoryBenchmarking)) | 831 switches::kEnableMemoryBenchmarking)) |
831 AddFilter(new MemoryBenchmarkMessageFilter()); | 832 AddFilter(new MemoryBenchmarkMessageFilter()); |
832 #endif | 833 #endif |
833 AddFilter(new VibrationMessageFilter()); | 834 AddFilter(new VibrationMessageFilter()); |
834 screen_orientation_dispatcher_host_ = new ScreenOrientationDispatcherHost(); | 835 screen_orientation_dispatcher_host_ = new ScreenOrientationDispatcherHost(); |
835 AddFilter(screen_orientation_dispatcher_host_); | 836 AddFilter(screen_orientation_dispatcher_host_); |
836 AddFilter(new PushMessagingMessageFilter()); | 837 AddFilter(new PushMessagingMessageFilter()); |
| 838 AddFilter(new TransitionRequestMessageFilter(GetID())); |
837 } | 839 } |
838 | 840 |
839 int RenderProcessHostImpl::GetNextRoutingID() { | 841 int RenderProcessHostImpl::GetNextRoutingID() { |
840 return widget_helper_->GetNextRoutingID(); | 842 return widget_helper_->GetNextRoutingID(); |
841 } | 843 } |
842 | 844 |
843 | 845 |
844 void RenderProcessHostImpl::ResumeDeferredNavigation( | 846 void RenderProcessHostImpl::ResumeDeferredNavigation( |
845 const GlobalRequestID& request_id) { | 847 const GlobalRequestID& request_id) { |
846 widget_helper_->ResumeDeferredNavigation(request_id); | 848 widget_helper_->ResumeDeferredNavigation(request_id); |
847 } | 849 } |
848 | 850 |
| 851 void RenderProcessHostImpl::ResumeResponseDeferredAtStart( |
| 852 const GlobalRequestID& request_id) { |
| 853 widget_helper_->ResumeResponseDeferredAtStart(request_id); |
| 854 } |
| 855 |
849 void RenderProcessHostImpl::NotifyTimezoneChange() { | 856 void RenderProcessHostImpl::NotifyTimezoneChange() { |
850 Send(new ViewMsg_TimezoneChange()); | 857 Send(new ViewMsg_TimezoneChange()); |
851 } | 858 } |
852 | 859 |
853 void RenderProcessHostImpl::AddRoute( | 860 void RenderProcessHostImpl::AddRoute( |
854 int32 routing_id, | 861 int32 routing_id, |
855 IPC::Listener* listener) { | 862 IPC::Listener* listener) { |
856 listeners_.AddWithID(listener, routing_id); | 863 listeners_.AddWithID(listener, routing_id); |
857 } | 864 } |
858 | 865 |
(...skipping 1215 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2074 mojo::ScopedMessagePipeHandle handle) { | 2081 mojo::ScopedMessagePipeHandle handle) { |
2075 mojo_activation_required_ = true; | 2082 mojo_activation_required_ = true; |
2076 MaybeActivateMojo(); | 2083 MaybeActivateMojo(); |
2077 | 2084 |
2078 mojo::AllocationScope scope; | 2085 mojo::AllocationScope scope; |
2079 mojo_application_host_->shell_client()->AcceptConnection(service_name, | 2086 mojo_application_host_->shell_client()->AcceptConnection(service_name, |
2080 handle.Pass()); | 2087 handle.Pass()); |
2081 } | 2088 } |
2082 | 2089 |
2083 } // namespace content | 2090 } // namespace content |
OLD | NEW |