| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #include "content/browser/renderer_host/pepper/pepper_renderer_connection.h" | 5 #include "content/browser/renderer_host/pepper/pepper_renderer_connection.h" |
| 6 | 6 |
| 7 #include "content/browser/browser_child_process_host_impl.h" | 7 #include "content/browser/browser_child_process_host_impl.h" |
| 8 #include "content/browser/ppapi_plugin_process_host.h" | 8 #include "content/browser/ppapi_plugin_process_host.h" |
| 9 #include "content/browser/renderer_host/pepper/browser_ppapi_host_impl.h" | 9 #include "content/browser/renderer_host/pepper/browser_ppapi_host_impl.h" |
| 10 #include "content/common/pepper_renderer_instance_data.h" | 10 #include "content/common/pepper_renderer_instance_data.h" |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 namespace content { | 21 namespace content { |
| 22 | 22 |
| 23 PepperRendererConnection::PepperRendererConnection(int render_process_id) | 23 PepperRendererConnection::PepperRendererConnection(int render_process_id) |
| 24 : render_process_id_(render_process_id) { | 24 : render_process_id_(render_process_id) { |
| 25 // Only give the renderer permission for stable APIs. | 25 // Only give the renderer permission for stable APIs. |
| 26 in_process_host_.reset(new BrowserPpapiHostImpl(this, | 26 in_process_host_.reset(new BrowserPpapiHostImpl(this, |
| 27 ppapi::PpapiPermissions(), | 27 ppapi::PpapiPermissions(), |
| 28 "", | 28 "", |
| 29 base::FilePath(), | 29 base::FilePath(), |
| 30 base::FilePath(), | 30 base::FilePath(), |
| 31 false)); | 31 false, |
| 32 NULL)); |
| 32 } | 33 } |
| 33 | 34 |
| 34 PepperRendererConnection::~PepperRendererConnection() { | 35 PepperRendererConnection::~PepperRendererConnection() { |
| 35 } | 36 } |
| 36 | 37 |
| 37 BrowserPpapiHostImpl* PepperRendererConnection::GetHostForChildProcess( | 38 BrowserPpapiHostImpl* PepperRendererConnection::GetHostForChildProcess( |
| 38 int child_process_id) const { | 39 int child_process_id) const { |
| 39 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); | 40 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); |
| 40 | 41 |
| 41 // Find the plugin which this message refers to. Check NaCl plugins first. | 42 // Find the plugin which this message refers to. Check NaCl plugins first. |
| (...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 167 data.render_process_id = render_process_id_; | 168 data.render_process_id = render_process_id_; |
| 168 in_process_host_->AddInstance(instance, data); | 169 in_process_host_->AddInstance(instance, data); |
| 169 } | 170 } |
| 170 | 171 |
| 171 void PepperRendererConnection::OnMsgDidDeleteInProcessInstance( | 172 void PepperRendererConnection::OnMsgDidDeleteInProcessInstance( |
| 172 PP_Instance instance) { | 173 PP_Instance instance) { |
| 173 in_process_host_->DeleteInstance(instance); | 174 in_process_host_->DeleteInstance(instance); |
| 174 } | 175 } |
| 175 | 176 |
| 176 } // namespace content | 177 } // namespace content |
| OLD | NEW |