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 // A BrowserPluginGuest is the browser side of a browser <--> embedder | 5 // A BrowserPluginGuest is the browser side of a browser <--> embedder |
6 // renderer channel. A BrowserPlugin (a WebPlugin) is on the embedder | 6 // renderer channel. A BrowserPlugin (a WebPlugin) is on the embedder |
7 // renderer side of browser <--> embedder renderer communication. | 7 // renderer side of browser <--> embedder renderer communication. |
8 // | 8 // |
9 // BrowserPluginGuest lives on the UI thread of the browser process. It has a | 9 // BrowserPluginGuest lives on the UI thread of the browser process. It has a |
10 // helper, BrowserPluginGuestHelper, which is a RenderViewHostObserver. The | 10 // helper, BrowserPluginGuestHelper, which is a RenderViewHostObserver. The |
(...skipping 23 matching lines...) Expand all Loading... |
34 #include "content/public/browser/web_contents_observer.h" | 34 #include "content/public/browser/web_contents_observer.h" |
35 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDragStatus.h" | 35 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDragStatus.h" |
36 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDragOperation.h" | 36 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDragOperation.h" |
37 #include "third_party/WebKit/Source/WebKit/chromium/public/WebInputEvent.h" | 37 #include "third_party/WebKit/Source/WebKit/chromium/public/WebInputEvent.h" |
38 #include "ui/gfx/rect.h" | 38 #include "ui/gfx/rect.h" |
39 #include "ui/surface/transport_dib.h" | 39 #include "ui/surface/transport_dib.h" |
40 | 40 |
41 struct BrowserPluginHostMsg_AutoSize_Params; | 41 struct BrowserPluginHostMsg_AutoSize_Params; |
42 struct BrowserPluginHostMsg_CreateGuest_Params; | 42 struct BrowserPluginHostMsg_CreateGuest_Params; |
43 struct BrowserPluginHostMsg_ResizeGuest_Params; | 43 struct BrowserPluginHostMsg_ResizeGuest_Params; |
| 44 struct ViewHostMsg_CreateWindow_Params; |
44 #if defined(OS_MACOSX) | 45 #if defined(OS_MACOSX) |
45 struct ViewHostMsg_ShowPopup_Params; | 46 struct ViewHostMsg_ShowPopup_Params; |
46 #endif | 47 #endif |
47 struct ViewHostMsg_UpdateRect_Params; | 48 struct ViewHostMsg_UpdateRect_Params; |
48 class WebCursor; | 49 class WebCursor; |
49 struct WebDropData; | 50 struct WebDropData; |
50 | 51 |
51 namespace WebKit { | 52 namespace WebKit { |
52 class WebInputEvent; | 53 class WebInputEvent; |
53 } | 54 } |
(...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
243 virtual void OnStop(int instance_id); | 244 virtual void OnStop(int instance_id); |
244 void OnTerminateGuest(int instance_id); | 245 void OnTerminateGuest(int instance_id); |
245 void OnUpdateRectACK( | 246 void OnUpdateRectACK( |
246 int instance_id, | 247 int instance_id, |
247 const BrowserPluginHostMsg_AutoSize_Params& auto_size_params, | 248 const BrowserPluginHostMsg_AutoSize_Params& auto_size_params, |
248 const BrowserPluginHostMsg_ResizeGuest_Params& resize_guest_params); | 249 const BrowserPluginHostMsg_ResizeGuest_Params& resize_guest_params); |
249 | 250 |
250 | 251 |
251 // Message handlers for messages from guest. | 252 // Message handlers for messages from guest. |
252 | 253 |
| 254 void OnCreateWindow(const ViewHostMsg_CreateWindow_Params& params, |
| 255 int* route_id, |
| 256 int* surface_id, |
| 257 int64* cloned_session_storage_namespace_id); |
253 void OnHandleInputEventAck( | 258 void OnHandleInputEventAck( |
254 WebKit::WebInputEvent::Type event_type, | 259 WebKit::WebInputEvent::Type event_type, |
255 InputEventAckState ack_result); | 260 InputEventAckState ack_result); |
256 void OnHasTouchEventHandlers(bool accept); | 261 void OnHasTouchEventHandlers(bool accept); |
257 void OnSetCursor(const WebCursor& cursor); | 262 void OnSetCursor(const WebCursor& cursor); |
258 // On MacOSX popups are painted by the browser process. We handle them here | 263 // On MacOSX popups are painted by the browser process. We handle them here |
259 // so that they are positioned correctly. | 264 // so that they are positioned correctly. |
260 #if defined(OS_MACOSX) | 265 #if defined(OS_MACOSX) |
261 void OnShowPopup(const ViewHostMsg_ShowPopup_Params& params); | 266 void OnShowPopup(const ViewHostMsg_ShowPopup_Params& params); |
262 #endif | 267 #endif |
(...skipping 25 matching lines...) Expand all Loading... |
288 bool auto_size_enabled_; | 293 bool auto_size_enabled_; |
289 gfx::Size max_auto_size_; | 294 gfx::Size max_auto_size_; |
290 gfx::Size min_auto_size_; | 295 gfx::Size min_auto_size_; |
291 | 296 |
292 DISALLOW_COPY_AND_ASSIGN(BrowserPluginGuest); | 297 DISALLOW_COPY_AND_ASSIGN(BrowserPluginGuest); |
293 }; | 298 }; |
294 | 299 |
295 } // namespace content | 300 } // namespace content |
296 | 301 |
297 #endif // CONTENT_BROWSER_BROWSER_PLUGIN_BROWSER_PLUGIN_GUEST_H_ | 302 #endif // CONTENT_BROWSER_BROWSER_PLUGIN_BROWSER_PLUGIN_GUEST_H_ |
OLD | NEW |