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 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
124 #include "ipc/ipc_switches.h" | 124 #include "ipc/ipc_switches.h" |
125 #include "media/base/media_switches.h" | 125 #include "media/base/media_switches.h" |
126 #include "net/url_request/url_request_context_getter.h" | 126 #include "net/url_request/url_request_context_getter.h" |
127 #include "ppapi/shared_impl/ppapi_switches.h" | 127 #include "ppapi/shared_impl/ppapi_switches.h" |
128 #include "ui/base/ui_base_switches.h" | 128 #include "ui/base/ui_base_switches.h" |
129 #include "ui/gl/gl_switches.h" | 129 #include "ui/gl/gl_switches.h" |
130 #include "webkit/browser/fileapi/sandbox_file_system_backend.h" | 130 #include "webkit/browser/fileapi/sandbox_file_system_backend.h" |
131 #include "webkit/glue/resource_type.h" | 131 #include "webkit/glue/resource_type.h" |
132 #include "webkit/plugins/plugin_switches.h" | 132 #include "webkit/plugins/plugin_switches.h" |
133 | 133 |
| 134 #if defined(OS_ANDROID) |
| 135 #include "content/browser/vibration/vibration_message_filter.h" |
| 136 #endif |
| 137 |
134 #if defined(OS_WIN) | 138 #if defined(OS_WIN) |
135 #include "base/win/scoped_com_initializer.h" | 139 #include "base/win/scoped_com_initializer.h" |
136 #include "content/common/font_cache_dispatcher_win.h" | 140 #include "content/common/font_cache_dispatcher_win.h" |
137 #include "content/common/sandbox_win.h" | 141 #include "content/common/sandbox_win.h" |
138 #include "content/public/common/sandboxed_process_launcher_delegate.h" | 142 #include "content/public/common/sandboxed_process_launcher_delegate.h" |
139 #endif | 143 #endif |
140 | 144 |
141 #if defined(ENABLE_WEBRTC) | 145 #if defined(ENABLE_WEBRTC) |
142 #include "content/browser/renderer_host/media/webrtc_identity_service_host.h" | 146 #include "content/browser/renderer_host/media/webrtc_identity_service_host.h" |
143 #endif | 147 #endif |
(...skipping 562 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
706 GetContentClient()->browser()->CreateQuotaPermissionContext())); | 710 GetContentClient()->browser()->CreateQuotaPermissionContext())); |
707 channel_->AddFilter(new GamepadBrowserMessageFilter()); | 711 channel_->AddFilter(new GamepadBrowserMessageFilter()); |
708 channel_->AddFilter(new ProfilerMessageFilter(PROCESS_TYPE_RENDERER)); | 712 channel_->AddFilter(new ProfilerMessageFilter(PROCESS_TYPE_RENDERER)); |
709 channel_->AddFilter(new HistogramMessageFilter()); | 713 channel_->AddFilter(new HistogramMessageFilter()); |
710 channel_->AddFilter(new HyphenatorMessageFilter(this)); | 714 channel_->AddFilter(new HyphenatorMessageFilter(this)); |
711 #if defined(USE_TCMALLOC) && (defined(OS_LINUX) || defined(OS_ANDROID)) | 715 #if defined(USE_TCMALLOC) && (defined(OS_LINUX) || defined(OS_ANDROID)) |
712 if (CommandLine::ForCurrentProcess()->HasSwitch( | 716 if (CommandLine::ForCurrentProcess()->HasSwitch( |
713 switches::kEnableMemoryBenchmarking)) | 717 switches::kEnableMemoryBenchmarking)) |
714 channel_->AddFilter(new MemoryBenchmarkMessageFilter()); | 718 channel_->AddFilter(new MemoryBenchmarkMessageFilter()); |
715 #endif | 719 #endif |
| 720 #if defined(OS_ANDROID) |
| 721 channel_->AddFilter(new VibrationMessageFilter()); |
| 722 #endif |
716 } | 723 } |
717 | 724 |
718 int RenderProcessHostImpl::GetNextRoutingID() { | 725 int RenderProcessHostImpl::GetNextRoutingID() { |
719 return widget_helper_->GetNextRoutingID(); | 726 return widget_helper_->GetNextRoutingID(); |
720 } | 727 } |
721 | 728 |
722 | 729 |
723 void RenderProcessHostImpl::ResumeDeferredNavigation( | 730 void RenderProcessHostImpl::ResumeDeferredNavigation( |
724 const GlobalRequestID& request_id) { | 731 const GlobalRequestID& request_id) { |
725 widget_helper_->ResumeDeferredNavigation(request_id); | 732 widget_helper_->ResumeDeferredNavigation(request_id); |
(...skipping 1051 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1777 // Skip widgets in other processes. | 1784 // Skip widgets in other processes. |
1778 if (widgets[i]->GetProcess()->GetID() != GetID()) | 1785 if (widgets[i]->GetProcess()->GetID() != GetID()) |
1779 continue; | 1786 continue; |
1780 | 1787 |
1781 RenderViewHost* rvh = RenderViewHost::From(widgets[i]); | 1788 RenderViewHost* rvh = RenderViewHost::From(widgets[i]); |
1782 rvh->UpdateWebkitPreferences(rvh->GetWebkitPreferences()); | 1789 rvh->UpdateWebkitPreferences(rvh->GetWebkitPreferences()); |
1783 } | 1790 } |
1784 } | 1791 } |
1785 | 1792 |
1786 } // namespace content | 1793 } // namespace content |
OLD | NEW |