OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_PLUGIN_PROCESS_HOST_H_ | 5 #ifndef CONTENT_BROWSER_PLUGIN_PROCESS_HOST_H_ |
6 #define CONTENT_BROWSER_PLUGIN_PROCESS_HOST_H_ | 6 #define CONTENT_BROWSER_PLUGIN_PROCESS_HOST_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "build/build_config.h" | 9 #include "build/build_config.h" |
10 | 10 |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
62 }; | 62 }; |
63 | 63 |
64 PluginProcessHost(); | 64 PluginProcessHost(); |
65 virtual ~PluginProcessHost(); | 65 virtual ~PluginProcessHost(); |
66 | 66 |
67 // Initialize the new plugin process, returning true on success. This must | 67 // Initialize the new plugin process, returning true on success. This must |
68 // be called before the object can be used. | 68 // be called before the object can be used. |
69 bool Init(const webkit::WebPluginInfo& info, const std::string& locale); | 69 bool Init(const webkit::WebPluginInfo& info, const std::string& locale); |
70 | 70 |
71 // Force the plugin process to shutdown (cleanly). | 71 // Force the plugin process to shutdown (cleanly). |
72 virtual void ForceShutdown(); | 72 virtual void ForceShutdown() OVERRIDE; |
73 | 73 |
74 virtual bool OnMessageReceived(const IPC::Message& msg) OVERRIDE; | 74 virtual bool OnMessageReceived(const IPC::Message& msg) OVERRIDE; |
75 virtual void OnChannelConnected(int32 peer_pid) OVERRIDE; | 75 virtual void OnChannelConnected(int32 peer_pid) OVERRIDE; |
76 virtual void OnChannelError() OVERRIDE; | 76 virtual void OnChannelError() OVERRIDE; |
77 | 77 |
78 // Tells the plugin process to create a new channel for communication with a | 78 // Tells the plugin process to create a new channel for communication with a |
79 // renderer. When the plugin process responds with the channel name, | 79 // renderer. When the plugin process responds with the channel name, |
80 // OnChannelOpened in the client is called. | 80 // OnChannelOpened in the client is called. |
81 void OpenChannelToPlugin(Client* client); | 81 void OpenChannelToPlugin(Client* client); |
82 | 82 |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
128 | 128 |
129 #if defined(OS_MACOSX) | 129 #if defined(OS_MACOSX) |
130 void OnPluginSelectWindow(uint32 window_id, gfx::Rect window_rect, | 130 void OnPluginSelectWindow(uint32 window_id, gfx::Rect window_rect, |
131 bool modal); | 131 bool modal); |
132 void OnPluginShowWindow(uint32 window_id, gfx::Rect window_rect, | 132 void OnPluginShowWindow(uint32 window_id, gfx::Rect window_rect, |
133 bool modal); | 133 bool modal); |
134 void OnPluginHideWindow(uint32 window_id, gfx::Rect window_rect); | 134 void OnPluginHideWindow(uint32 window_id, gfx::Rect window_rect); |
135 void OnPluginSetCursorVisibility(bool visible); | 135 void OnPluginSetCursorVisibility(bool visible); |
136 #endif | 136 #endif |
137 | 137 |
138 virtual bool CanShutdown(); | 138 virtual bool CanShutdown() OVERRIDE; |
139 | 139 |
140 void CancelRequests(); | 140 void CancelRequests(); |
141 | 141 |
142 // These are channel requests that we are waiting to send to the | 142 // These are channel requests that we are waiting to send to the |
143 // plugin process once the channel is opened. | 143 // plugin process once the channel is opened. |
144 std::vector<Client*> pending_requests_; | 144 std::vector<Client*> pending_requests_; |
145 | 145 |
146 // These are the channel requests that we have already sent to | 146 // These are the channel requests that we have already sent to |
147 // the plugin process, but haven't heard back about yet. | 147 // the plugin process, but haven't heard back about yet. |
148 std::list<Client*> sent_requests_; | 148 std::list<Client*> sent_requests_; |
(...skipping 13 matching lines...) Expand all Loading... |
162 // Tracks modal windows currently visible. | 162 // Tracks modal windows currently visible. |
163 std::set<uint32> plugin_modal_windows_set_; | 163 std::set<uint32> plugin_modal_windows_set_; |
164 // Tracks the current visibility of the cursor. | 164 // Tracks the current visibility of the cursor. |
165 bool plugin_cursor_visible_; | 165 bool plugin_cursor_visible_; |
166 #endif | 166 #endif |
167 | 167 |
168 DISALLOW_COPY_AND_ASSIGN(PluginProcessHost); | 168 DISALLOW_COPY_AND_ASSIGN(PluginProcessHost); |
169 }; | 169 }; |
170 | 170 |
171 #endif // CONTENT_BROWSER_PLUGIN_PROCESS_HOST_H_ | 171 #endif // CONTENT_BROWSER_PLUGIN_PROCESS_HOST_H_ |
OLD | NEW |