OLD | NEW |
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 #ifndef CONTENT_BROWSER_PPAPI_PLUGIN_PROCESS_HOST_H_ | 5 #ifndef CONTENT_BROWSER_PPAPI_PLUGIN_PROCESS_HOST_H_ |
6 #define CONTENT_BROWSER_PPAPI_PLUGIN_PROCESS_HOST_H_ | 6 #define CONTENT_BROWSER_PPAPI_PLUGIN_PROCESS_HOST_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <queue> | 9 #include <queue> |
10 | 10 |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
73 | 73 |
74 virtual ~PpapiPluginProcessHost(); | 74 virtual ~PpapiPluginProcessHost(); |
75 | 75 |
76 static PpapiPluginProcessHost* CreatePluginHost( | 76 static PpapiPluginProcessHost* CreatePluginHost( |
77 const content::PepperPluginInfo& info, | 77 const content::PepperPluginInfo& info, |
78 const FilePath& profile_data_directory, | 78 const FilePath& profile_data_directory, |
79 net::HostResolver* host_resolver); | 79 net::HostResolver* host_resolver); |
80 static PpapiPluginProcessHost* CreateBrokerHost( | 80 static PpapiPluginProcessHost* CreateBrokerHost( |
81 const content::PepperPluginInfo& info); | 81 const content::PepperPluginInfo& info); |
82 | 82 |
| 83 // Notification that a PP_Instance has been created for the given |
| 84 // RenderView/Process pair for the given plugin. This is necessary so that |
| 85 // when the plugin calls us with a PP_Instance we can find the RenderView |
| 86 // associated with it without trusting the plugin. |
| 87 static void DidCreateOutOfProcessInstance(int plugin_process_id, |
| 88 int32 pp_instance, |
| 89 int render_process_id, |
| 90 int render_view_id); |
| 91 |
| 92 // The opposite of DIdCreate... above. |
| 93 static void DidDeleteOutOfProcessInstance(int plugin_process_id, |
| 94 int32 pp_instance); |
| 95 |
83 // IPC::Sender implementation: | 96 // IPC::Sender implementation: |
84 virtual bool Send(IPC::Message* message) OVERRIDE; | 97 virtual bool Send(IPC::Message* message) OVERRIDE; |
85 | 98 |
86 // Opens a new channel to the plugin. The client will be notified when the | 99 // Opens a new channel to the plugin. The client will be notified when the |
87 // channel is ready or if there's an error. | 100 // channel is ready or if there's an error. |
88 void OpenChannelToPlugin(Client* client); | 101 void OpenChannelToPlugin(Client* client); |
89 | 102 |
90 const FilePath& plugin_path() const { return plugin_path_; } | 103 const FilePath& plugin_path() const { return plugin_path_; } |
91 const FilePath& profile_data_directory() const { | 104 const FilePath& profile_data_directory() const { |
92 return profile_data_directory_; | 105 return profile_data_directory_; |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
166 : public content::BrowserChildProcessHostTypeIterator< | 179 : public content::BrowserChildProcessHostTypeIterator< |
167 PpapiPluginProcessHost> { | 180 PpapiPluginProcessHost> { |
168 public: | 181 public: |
169 PpapiBrokerProcessHostIterator() | 182 PpapiBrokerProcessHostIterator() |
170 : content::BrowserChildProcessHostTypeIterator< | 183 : content::BrowserChildProcessHostTypeIterator< |
171 PpapiPluginProcessHost>(content::PROCESS_TYPE_PPAPI_BROKER) {} | 184 PpapiPluginProcessHost>(content::PROCESS_TYPE_PPAPI_BROKER) {} |
172 }; | 185 }; |
173 | 186 |
174 #endif // CONTENT_BROWSER_PPAPI_PLUGIN_PROCESS_HOST_H_ | 187 #endif // CONTENT_BROWSER_PPAPI_PLUGIN_PROCESS_HOST_H_ |
175 | 188 |
OLD | NEW |