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 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
60 #include "content/browser/indexed_db/indexed_db_dispatcher_host.h" | 60 #include "content/browser/indexed_db/indexed_db_dispatcher_host.h" |
61 #include "content/browser/loader/resource_message_filter.h" | 61 #include "content/browser/loader/resource_message_filter.h" |
62 #include "content/browser/loader/resource_scheduler_filter.h" | 62 #include "content/browser/loader/resource_scheduler_filter.h" |
63 #include "content/browser/media/android/browser_demuxer_android.h" | 63 #include "content/browser/media/android/browser_demuxer_android.h" |
64 #include "content/browser/media/capture/audio_mirroring_manager.h" | 64 #include "content/browser/media/capture/audio_mirroring_manager.h" |
65 #include "content/browser/media/media_internals.h" | 65 #include "content/browser/media/media_internals.h" |
66 #include "content/browser/message_port_message_filter.h" | 66 #include "content/browser/message_port_message_filter.h" |
67 #include "content/browser/mime_registry_message_filter.h" | 67 #include "content/browser/mime_registry_message_filter.h" |
68 #include "content/browser/plugin_service_impl.h" | 68 #include "content/browser/plugin_service_impl.h" |
69 #include "content/browser/profiler_message_filter.h" | 69 #include "content/browser/profiler_message_filter.h" |
| 70 #include "content/browser/push_messaging_message_filter.h" |
70 #include "content/browser/quota_dispatcher_host.h" | 71 #include "content/browser/quota_dispatcher_host.h" |
71 #include "content/browser/renderer_host/clipboard_message_filter.h" | 72 #include "content/browser/renderer_host/clipboard_message_filter.h" |
72 #include "content/browser/renderer_host/database_message_filter.h" | 73 #include "content/browser/renderer_host/database_message_filter.h" |
73 #include "content/browser/renderer_host/file_utilities_message_filter.h" | 74 #include "content/browser/renderer_host/file_utilities_message_filter.h" |
74 #include "content/browser/renderer_host/gamepad_browser_message_filter.h" | 75 #include "content/browser/renderer_host/gamepad_browser_message_filter.h" |
75 #include "content/browser/renderer_host/gpu_message_filter.h" | 76 #include "content/browser/renderer_host/gpu_message_filter.h" |
76 #include "content/browser/renderer_host/media/audio_input_renderer_host.h" | 77 #include "content/browser/renderer_host/media/audio_input_renderer_host.h" |
77 #include "content/browser/renderer_host/media/audio_renderer_host.h" | 78 #include "content/browser/renderer_host/media/audio_renderer_host.h" |
78 #include "content/browser/renderer_host/media/device_request_message_filter.h" | 79 #include "content/browser/renderer_host/media/device_request_message_filter.h" |
79 #include "content/browser/renderer_host/media/media_stream_dispatcher_host.h" | 80 #include "content/browser/renderer_host/media/media_stream_dispatcher_host.h" |
(...skipping 753 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
833 AddFilter(new ProfilerMessageFilter(PROCESS_TYPE_RENDERER)); | 834 AddFilter(new ProfilerMessageFilter(PROCESS_TYPE_RENDERER)); |
834 AddFilter(new HistogramMessageFilter()); | 835 AddFilter(new HistogramMessageFilter()); |
835 #if defined(USE_TCMALLOC) && (defined(OS_LINUX) || defined(OS_ANDROID)) | 836 #if defined(USE_TCMALLOC) && (defined(OS_LINUX) || defined(OS_ANDROID)) |
836 if (CommandLine::ForCurrentProcess()->HasSwitch( | 837 if (CommandLine::ForCurrentProcess()->HasSwitch( |
837 switches::kEnableMemoryBenchmarking)) | 838 switches::kEnableMemoryBenchmarking)) |
838 AddFilter(new MemoryBenchmarkMessageFilter()); | 839 AddFilter(new MemoryBenchmarkMessageFilter()); |
839 #endif | 840 #endif |
840 AddFilter(new VibrationMessageFilter()); | 841 AddFilter(new VibrationMessageFilter()); |
841 screen_orientation_dispatcher_host_ = new ScreenOrientationDispatcherHost(); | 842 screen_orientation_dispatcher_host_ = new ScreenOrientationDispatcherHost(); |
842 AddFilter(screen_orientation_dispatcher_host_); | 843 AddFilter(screen_orientation_dispatcher_host_); |
| 844 AddFilter(new PushMessagingMessageFilter()); |
843 } | 845 } |
844 | 846 |
845 int RenderProcessHostImpl::GetNextRoutingID() { | 847 int RenderProcessHostImpl::GetNextRoutingID() { |
846 return widget_helper_->GetNextRoutingID(); | 848 return widget_helper_->GetNextRoutingID(); |
847 } | 849 } |
848 | 850 |
849 | 851 |
850 void RenderProcessHostImpl::ResumeDeferredNavigation( | 852 void RenderProcessHostImpl::ResumeDeferredNavigation( |
851 const GlobalRequestID& request_id) { | 853 const GlobalRequestID& request_id) { |
852 widget_helper_->ResumeDeferredNavigation(request_id); | 854 widget_helper_->ResumeDeferredNavigation(request_id); |
(...skipping 1311 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2164 void RenderProcessHostImpl::SetWebUIHandle( | 2166 void RenderProcessHostImpl::SetWebUIHandle( |
2165 int32 view_routing_id, | 2167 int32 view_routing_id, |
2166 mojo::ScopedMessagePipeHandle handle) { | 2168 mojo::ScopedMessagePipeHandle handle) { |
2167 if (!render_process_host_mojo_) | 2169 if (!render_process_host_mojo_) |
2168 render_process_host_mojo_.reset(new RenderProcessHostMojoImpl(this)); | 2170 render_process_host_mojo_.reset(new RenderProcessHostMojoImpl(this)); |
2169 render_process_host_mojo_->SetWebUIHandle(view_routing_id, handle.Pass()); | 2171 render_process_host_mojo_->SetWebUIHandle(view_routing_id, handle.Pass()); |
2170 } | 2172 } |
2171 #endif | 2173 #endif |
2172 | 2174 |
2173 } // namespace content | 2175 } // namespace content |
OLD | NEW |