Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5)

Side by Side Diff: content/renderer/pepper/pepper_plugin_delegate_impl.cc

Issue 15947004: Allow renderer to create pepper ResourceHosts in the browser (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 #include "content/renderer/pepper/pepper_plugin_delegate_impl.h" 5 #include "content/renderer/pepper/pepper_plugin_delegate_impl.h"
6 6
7 #include <cmath> 7 #include <cmath>
8 #include <cstddef> 8 #include <cstddef>
9 #include <map> 9 #include <map>
10 #include <queue> 10 #include <queue>
(...skipping 185 matching lines...) Expand 10 before | Expand all | Expand 10 after
196 render_view->Send(new ViewHostMsg_DidDeleteOutOfProcessPepperInstance( 196 render_view->Send(new ViewHostMsg_DidDeleteOutOfProcessPepperInstance(
197 plugin_child_id_, 197 plugin_child_id_,
198 instance, 198 instance,
199 is_external_)); 199 is_external_));
200 } 200 }
201 } 201 }
202 virtual base::ProcessId GetPeerProcessId() OVERRIDE { 202 virtual base::ProcessId GetPeerProcessId() OVERRIDE {
203 return peer_pid_; 203 return peer_pid_;
204 } 204 }
205 205
206 virtual int GetPluginChildId() OVERRIDE {
207 return plugin_child_id_;
208 }
209
206 ppapi::proxy::HostDispatcher* dispatcher() { return dispatcher_.get(); } 210 ppapi::proxy::HostDispatcher* dispatcher() { return dispatcher_.get(); }
207 211
208 private: 212 private:
209 webkit::ppapi::PluginModule* module_; 213 webkit::ppapi::PluginModule* module_;
210 214
211 base::ProcessId peer_pid_; 215 base::ProcessId peer_pid_;
212 216
213 // ID that the browser process uses to idetify the child process for the 217 // ID that the browser process uses to idetify the child process for the
214 // plugin. This isn't directly useful from our process (the renderer) except 218 // plugin. This isn't directly useful from our process (the renderer) except
215 // in messages to the browser to disambiguate plugins. 219 // in messages to the browser to disambiguate plugins.
(...skipping 1470 matching lines...) Expand 10 before | Expand all | Expand 10 after
1686 should_close_source); 1690 should_close_source);
1687 } 1691 }
1688 1692
1689 bool PepperPluginDelegateImpl::IsRunningInProcess(PP_Instance instance) const { 1693 bool PepperPluginDelegateImpl::IsRunningInProcess(PP_Instance instance) const {
1690 RendererPpapiHostImpl* host = 1694 RendererPpapiHostImpl* host =
1691 RendererPpapiHostImpl::GetForPPInstance(instance); 1695 RendererPpapiHostImpl::GetForPPInstance(instance);
1692 return host && host->IsRunningInProcess(); 1696 return host && host->IsRunningInProcess();
1693 } 1697 }
1694 1698
1695 } // namespace content 1699 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698