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 WEBKIT_PLUGINS_NPAPI_WEBPLUGIN_IMPL_H_ | 5 #ifndef WEBKIT_PLUGINS_NPAPI_WEBPLUGIN_IMPL_H_ |
6 #define WEBKIT_PLUGINS_NPAPI_WEBPLUGIN_IMPL_H_ | 6 #define WEBKIT_PLUGINS_NPAPI_WEBPLUGIN_IMPL_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 uint32 length); | 68 uint32 length); |
69 | 69 |
70 virtual WebPluginDelegate* delegate(); | 70 virtual WebPluginDelegate* delegate(); |
71 | 71 |
72 private: | 72 private: |
73 // WebKit::WebPlugin methods: | 73 // WebKit::WebPlugin methods: |
74 virtual bool initialize( | 74 virtual bool initialize( |
75 WebKit::WebPluginContainer* container); | 75 WebKit::WebPluginContainer* container); |
76 virtual void destroy(); | 76 virtual void destroy(); |
77 virtual NPObject* scriptableObject(); | 77 virtual NPObject* scriptableObject(); |
78 virtual struct _NPP* pluginNPP(); | |
79 virtual bool getFormValue(WebKit::WebString& value); | 78 virtual bool getFormValue(WebKit::WebString& value); |
80 virtual void paint( | 79 virtual void paint( |
81 WebKit::WebCanvas* canvas, const WebKit::WebRect& paint_rect); | 80 WebKit::WebCanvas* canvas, const WebKit::WebRect& paint_rect); |
82 virtual void updateGeometry( | 81 virtual void updateGeometry( |
83 const WebKit::WebRect& frame_rect, const WebKit::WebRect& clip_rect, | 82 const WebKit::WebRect& frame_rect, const WebKit::WebRect& clip_rect, |
84 const WebKit::WebVector<WebKit::WebRect>& cut_outs, bool is_visible); | 83 const WebKit::WebVector<WebKit::WebRect>& cut_outs, bool is_visible); |
85 virtual void updateFocus(bool focused); | 84 virtual void updateFocus(bool focused); |
86 virtual void updateVisibility(bool visible); | 85 virtual void updateVisibility(bool visible); |
87 virtual bool acceptsInputEvents(); | 86 virtual bool acceptsInputEvents(); |
88 virtual bool handleInputEvent( | 87 virtual bool handleInputEvent( |
(...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
286 #endif | 285 #endif |
287 bool accepts_input_events_; | 286 bool accepts_input_events_; |
288 base::WeakPtr<WebPluginPageDelegate> page_delegate_; | 287 base::WeakPtr<WebPluginPageDelegate> page_delegate_; |
289 WebKit::WebFrame* webframe_; | 288 WebKit::WebFrame* webframe_; |
290 | 289 |
291 WebPluginDelegate* delegate_; | 290 WebPluginDelegate* delegate_; |
292 | 291 |
293 // This is just a weak reference. | 292 // This is just a weak reference. |
294 WebKit::WebPluginContainer* container_; | 293 WebKit::WebPluginContainer* container_; |
295 | 294 |
296 // Unique identifier for this plugin, used to track script objects. | |
297 struct _NPP* npp_; | |
298 | |
299 typedef std::map<WebPluginResourceClient*, | 295 typedef std::map<WebPluginResourceClient*, |
300 webkit_glue::MultipartResponseDelegate*> | 296 webkit_glue::MultipartResponseDelegate*> |
301 MultiPartResponseHandlerMap; | 297 MultiPartResponseHandlerMap; |
302 // Tracks HTTP multipart response handlers instantiated for | 298 // Tracks HTTP multipart response handlers instantiated for |
303 // a WebPluginResourceClient instance. | 299 // a WebPluginResourceClient instance. |
304 MultiPartResponseHandlerMap multi_part_response_map_; | 300 MultiPartResponseHandlerMap multi_part_response_map_; |
305 | 301 |
306 // The plugin source URL. | 302 // The plugin source URL. |
307 GURL plugin_url_; | 303 GURL plugin_url_; |
308 | 304 |
(...skipping 22 matching lines...) Expand all Loading... |
331 | 327 |
332 base::WeakPtrFactory<WebPluginImpl> weak_factory_; | 328 base::WeakPtrFactory<WebPluginImpl> weak_factory_; |
333 | 329 |
334 DISALLOW_COPY_AND_ASSIGN(WebPluginImpl); | 330 DISALLOW_COPY_AND_ASSIGN(WebPluginImpl); |
335 }; | 331 }; |
336 | 332 |
337 } // namespace npapi | 333 } // namespace npapi |
338 } // namespace webkit | 334 } // namespace webkit |
339 | 335 |
340 #endif // WEBKIT_PLUGINS_NPAPI_WEBPLUGIN_IMPL_H_ | 336 #endif // WEBKIT_PLUGINS_NPAPI_WEBPLUGIN_IMPL_H_ |
OLD | NEW |