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 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
181 #include "ui/display/display_switches.h" | 181 #include "ui/display/display_switches.h" |
182 #include "ui/events/event_switches.h" | 182 #include "ui/events/event_switches.h" |
183 #include "ui/gfx/switches.h" | 183 #include "ui/gfx/switches.h" |
184 #include "ui/gl/gl_switches.h" | 184 #include "ui/gl/gl_switches.h" |
185 #include "ui/gl/gpu_switching_manager.h" | 185 #include "ui/gl/gpu_switching_manager.h" |
186 #include "ui/native_theme/native_theme_switches.h" | 186 #include "ui/native_theme/native_theme_switches.h" |
187 | 187 |
188 #if defined(OS_ANDROID) | 188 #if defined(OS_ANDROID) |
189 #include "content/browser/android/child_process_launcher_android.h" | 189 #include "content/browser/android/child_process_launcher_android.h" |
190 #include "content/browser/media/android/browser_demuxer_android.h" | 190 #include "content/browser/media/android/browser_demuxer_android.h" |
191 #include "content/browser/mojo/service_registrar_android.h" | 191 #include "content/browser/mojo/interface_registrar_android.h" |
192 #include "content/browser/screen_orientation/screen_orientation_message_filter_a
ndroid.h" | 192 #include "content/browser/screen_orientation/screen_orientation_message_filter_a
ndroid.h" |
193 #include "ipc/ipc_sync_channel.h" | 193 #include "ipc/ipc_sync_channel.h" |
194 #include "media/audio/android/audio_manager_android.h" | 194 #include "media/audio/android/audio_manager_android.h" |
195 #endif | 195 #endif |
196 | 196 |
197 #if defined(OS_WIN) | 197 #if defined(OS_WIN) |
198 #include "base/win/scoped_com_initializer.h" | 198 #include "base/win/scoped_com_initializer.h" |
199 #include "base/win/windows_version.h" | 199 #include "base/win/windows_version.h" |
200 #include "content/browser/renderer_host/dwrite_font_proxy_message_filter_win.h" | 200 #include "content/browser/renderer_host/dwrite_font_proxy_message_filter_win.h" |
201 #include "content/common/font_cache_dispatcher_win.h" | 201 #include "content/common/font_cache_dispatcher_win.h" |
(...skipping 900 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1102 base::Bind(&DeviceOrientationHost::Create), io_task_runner); | 1102 base::Bind(&DeviceOrientationHost::Create), io_task_runner); |
1103 GetInterfaceRegistry()->AddInterface( | 1103 GetInterfaceRegistry()->AddInterface( |
1104 base::Bind(&DeviceOrientationAbsoluteHost::Create), io_task_runner); | 1104 base::Bind(&DeviceOrientationAbsoluteHost::Create), io_task_runner); |
1105 | 1105 |
1106 if (memory_coordinator::IsEnabled()) { | 1106 if (memory_coordinator::IsEnabled()) { |
1107 GetInterfaceRegistry()->AddInterface( | 1107 GetInterfaceRegistry()->AddInterface( |
1108 base::Bind(&CreateMemoryCoordinatorHandle, GetID())); | 1108 base::Bind(&CreateMemoryCoordinatorHandle, GetID())); |
1109 } | 1109 } |
1110 | 1110 |
1111 #if defined(OS_ANDROID) | 1111 #if defined(OS_ANDROID) |
1112 ServiceRegistrarAndroid::RegisterProcessHostServices( | 1112 InterfaceRegistrarAndroid::ExposeInterfacesToRenderer( |
1113 mojo_child_connection_->service_registry_android()); | 1113 mojo_child_connection_->interface_registry_android()); |
1114 #endif | 1114 #endif |
1115 | 1115 |
1116 GetContentClient()->browser()->ExposeInterfacesToRenderer( | 1116 GetContentClient()->browser()->ExposeInterfacesToRenderer( |
1117 GetInterfaceRegistry(), this); | 1117 GetInterfaceRegistry(), this); |
1118 } | 1118 } |
1119 | 1119 |
1120 void RenderProcessHostImpl::CreateStoragePartitionService( | 1120 void RenderProcessHostImpl::CreateStoragePartitionService( |
1121 mojo::InterfaceRequest<mojom::StoragePartitionService> request) { | 1121 mojo::InterfaceRequest<mojom::StoragePartitionService> request) { |
1122 // DO NOT REMOVE THIS COMMAND LINE CHECK WITHOUT SECURITY REVIEW! | 1122 // DO NOT REMOVE THIS COMMAND LINE CHECK WITHOUT SECURITY REVIEW! |
1123 if (base::CommandLine::ForCurrentProcess()->HasSwitch( | 1123 if (base::CommandLine::ForCurrentProcess()->HasSwitch( |
(...skipping 1638 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2762 LOG(ERROR) << "Terminating render process for bad Mojo message: " << error; | 2762 LOG(ERROR) << "Terminating render process for bad Mojo message: " << error; |
2763 | 2763 |
2764 // The ReceivedBadMessage call below will trigger a DumpWithoutCrashing. Alias | 2764 // The ReceivedBadMessage call below will trigger a DumpWithoutCrashing. Alias |
2765 // enough information here so that we can determine what the bad message was. | 2765 // enough information here so that we can determine what the bad message was. |
2766 base::debug::Alias(&error); | 2766 base::debug::Alias(&error); |
2767 bad_message::ReceivedBadMessage(process.get(), | 2767 bad_message::ReceivedBadMessage(process.get(), |
2768 bad_message::RPH_MOJO_PROCESS_ERROR); | 2768 bad_message::RPH_MOJO_PROCESS_ERROR); |
2769 } | 2769 } |
2770 | 2770 |
2771 } // namespace content | 2771 } // namespace content |
OLD | NEW |