Chromium Code Reviews| 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 "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/memory/ref_counted.h" | 8 #include "base/memory/ref_counted.h" |
| 9 #include "content/browser/browser_child_process_host_impl.h" | 9 #include "content/browser/browser_child_process_host_impl.h" |
| 10 #include "content/browser/ppapi_plugin_process_host.h" | 10 #include "content/browser/ppapi_plugin_process_host.h" |
| (...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 131 | 131 |
| 132 return host; | 132 return host; |
| 133 } | 133 } |
| 134 | 134 |
| 135 bool PepperRendererConnection::OnMessageReceived(const IPC::Message& msg, | 135 bool PepperRendererConnection::OnMessageReceived(const IPC::Message& msg, |
| 136 bool* message_was_ok) { | 136 bool* message_was_ok) { |
| 137 if (in_process_host_->GetPpapiHost()->OnMessageReceived(msg)) | 137 if (in_process_host_->GetPpapiHost()->OnMessageReceived(msg)) |
| 138 return true; | 138 return true; |
| 139 | 139 |
| 140 bool handled = true; | 140 bool handled = true; |
| 141 IPC_BEGIN_MESSAGE_MAP_EX(PepperRendererConnection, msg, *message_was_ok) | 141 IPC_BEGIN_MESSAGE_MAP_EX(PepperRendererConnection, msg, *message_was_ok) |
|
Tom Sepez
2014/05/13 20:03:47
Did you mean to convert this to PPAPI_BEGIN_MESSAG
| |
| 142 IPC_MESSAGE_HANDLER(PpapiHostMsg_CreateResourceHostsFromHost, | 142 IPC_MESSAGE_HANDLER(PpapiHostMsg_CreateResourceHostsFromHost, |
| 143 OnMsgCreateResourceHostsFromHost) | 143 OnMsgCreateResourceHostsFromHost) |
| 144 IPC_MESSAGE_HANDLER(ViewHostMsg_DidCreateInProcessInstance, | 144 IPC_MESSAGE_HANDLER(ViewHostMsg_DidCreateInProcessInstance, |
| 145 OnMsgDidCreateInProcessInstance) | 145 OnMsgDidCreateInProcessInstance) |
| 146 IPC_MESSAGE_HANDLER(ViewHostMsg_DidDeleteInProcessInstance, | 146 IPC_MESSAGE_HANDLER(ViewHostMsg_DidDeleteInProcessInstance, |
| 147 OnMsgDidDeleteInProcessInstance) | 147 OnMsgDidDeleteInProcessInstance) |
| 148 IPC_MESSAGE_UNHANDLED(handled = false) | 148 IPC_MESSAGE_UNHANDLED(handled = false) |
| 149 IPC_END_MESSAGE_MAP_EX() | 149 IPC_END_MESSAGE_MAP_EX() |
| 150 | 150 |
| 151 return handled; | 151 return handled; |
| 152 } | 152 } |
| 153 | 153 |
| 154 void PepperRendererConnection::OnMsgCreateResourceHostsFromHost( | 154 void PepperRendererConnection::OnMsgCreateResourceHostsFromHost( |
| 155 int routing_id, | 155 int routing_id, |
| 156 int child_process_id, | 156 int child_process_id, |
| 157 const ppapi::proxy::ResourceMessageCallParams& params, | 157 const ppapi::proxy::ResourceMessageCallParams& params, |
| 158 PP_Instance instance, | 158 PP_Instance instance, |
| (...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 229 data.render_process_id = render_process_id_; | 229 data.render_process_id = render_process_id_; |
| 230 in_process_host_->AddInstance(instance, data); | 230 in_process_host_->AddInstance(instance, data); |
| 231 } | 231 } |
| 232 | 232 |
| 233 void PepperRendererConnection::OnMsgDidDeleteInProcessInstance( | 233 void PepperRendererConnection::OnMsgDidDeleteInProcessInstance( |
| 234 PP_Instance instance) { | 234 PP_Instance instance) { |
| 235 in_process_host_->DeleteInstance(instance); | 235 in_process_host_->DeleteInstance(instance); |
| 236 } | 236 } |
| 237 | 237 |
| 238 } // namespace content | 238 } // namespace content |
| OLD | NEW |