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 172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
183 #include "content/common/sandbox_win.h" | 183 #include "content/common/sandbox_win.h" |
184 #include "sandbox/win/src/sandbox_policy.h" | 184 #include "sandbox/win/src/sandbox_policy.h" |
185 #include "ui/gfx/win/dpi.h" | 185 #include "ui/gfx/win/dpi.h" |
186 #endif | 186 #endif |
187 | 187 |
188 #if defined(OS_MACOSX) && !defined(OS_IOS) | 188 #if defined(OS_MACOSX) && !defined(OS_IOS) |
189 #include "content/browser/browser_io_surface_manager_mac.h" | 189 #include "content/browser/browser_io_surface_manager_mac.h" |
190 #endif | 190 #endif |
191 | 191 |
192 #if defined(USE_OZONE) | 192 #if defined(USE_OZONE) |
193 #include "ui/ozone/public/client_native_pixmap_factory.h" | |
193 #include "ui/ozone/public/ozone_switches.h" | 194 #include "ui/ozone/public/ozone_switches.h" |
194 #endif | 195 #endif |
195 | 196 |
196 #if defined(ENABLE_BROWSER_CDMS) | 197 #if defined(ENABLE_BROWSER_CDMS) |
197 #include "content/browser/media/cdm/browser_cdm_manager.h" | 198 #include "content/browser/media/cdm/browser_cdm_manager.h" |
198 #endif | 199 #endif |
199 | 200 |
200 #if defined(ENABLE_PLUGINS) | 201 #if defined(ENABLE_PLUGINS) |
201 #include "content/browser/plugin_service_impl.h" | 202 #include "content/browser/plugin_service_impl.h" |
202 #endif | 203 #endif |
(...skipping 1390 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1593 tracked_objects::ThreadData::Status status = | 1594 tracked_objects::ThreadData::Status status = |
1594 tracked_objects::ThreadData::status(); | 1595 tracked_objects::ThreadData::status(); |
1595 Send(new ChildProcessMsg_SetProfilerStatus(status)); | 1596 Send(new ChildProcessMsg_SetProfilerStatus(status)); |
1596 | 1597 |
1597 #if defined(OS_MACOSX) && !defined(OS_IOS) | 1598 #if defined(OS_MACOSX) && !defined(OS_IOS) |
1598 io_surface_manager_token_ = | 1599 io_surface_manager_token_ = |
1599 BrowserIOSurfaceManager::GetInstance()->GenerateChildProcessToken( | 1600 BrowserIOSurfaceManager::GetInstance()->GenerateChildProcessToken( |
1600 GetID()); | 1601 GetID()); |
1601 Send(new ChildProcessMsg_SetIOSurfaceManagerToken(io_surface_manager_token_)); | 1602 Send(new ChildProcessMsg_SetIOSurfaceManagerToken(io_surface_manager_token_)); |
1602 #endif | 1603 #endif |
1604 #if defined(USE_OZONE) | |
1605 auto vgem_fd(ui::ClientNativePixmapFactory::GetInstance()->OpenVgemFD()); | |
spang
2015/08/17 18:03:41
and here.
| |
1606 Send(new ChildProcessMsg_SetVgemFD(base::FileDescriptor(vgem_fd->Pass()))); | |
1607 #endif | |
1603 } | 1608 } |
1604 | 1609 |
1605 void RenderProcessHostImpl::OnChannelError() { | 1610 void RenderProcessHostImpl::OnChannelError() { |
1606 ProcessDied(true /* already_dead */, nullptr); | 1611 ProcessDied(true /* already_dead */, nullptr); |
1607 } | 1612 } |
1608 | 1613 |
1609 void RenderProcessHostImpl::OnBadMessageReceived(const IPC::Message& message) { | 1614 void RenderProcessHostImpl::OnBadMessageReceived(const IPC::Message& message) { |
1610 // Message de-serialization failed. We consider this a capital crime. Kill the | 1615 // Message de-serialization failed. We consider this a capital crime. Kill the |
1611 // renderer if we have one. | 1616 // renderer if we have one. |
1612 LOG(ERROR) << "bad message " << message.type() << " terminating renderer."; | 1617 LOG(ERROR) << "bad message " << message.type() << " terminating renderer."; |
(...skipping 914 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2527 void RenderProcessHostImpl::GetAudioOutputControllers( | 2532 void RenderProcessHostImpl::GetAudioOutputControllers( |
2528 const GetAudioOutputControllersCallback& callback) const { | 2533 const GetAudioOutputControllersCallback& callback) const { |
2529 audio_renderer_host()->GetOutputControllers(callback); | 2534 audio_renderer_host()->GetOutputControllers(callback); |
2530 } | 2535 } |
2531 | 2536 |
2532 BluetoothDispatcherHost* RenderProcessHostImpl::GetBluetoothDispatcherHost() { | 2537 BluetoothDispatcherHost* RenderProcessHostImpl::GetBluetoothDispatcherHost() { |
2533 return bluetooth_dispatcher_host_.get(); | 2538 return bluetooth_dispatcher_host_.get(); |
2534 } | 2539 } |
2535 | 2540 |
2536 } // namespace content | 2541 } // namespace content |
OLD | NEW |