| 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 WEBKIT_PLUGINS_PPAPI_PPAPI_WEBPLUGIN_IMPL_H_ | 5 #ifndef WEBKIT_PLUGINS_PPAPI_PPAPI_WEBPLUGIN_IMPL_H_ |
| 6 #define WEBKIT_PLUGINS_PPAPI_PPAPI_WEBPLUGIN_IMPL_H_ | 6 #define WEBKIT_PLUGINS_PPAPI_PPAPI_WEBPLUGIN_IMPL_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| 11 #include "base/memory/scoped_ptr.h" | 11 #include "base/memory/scoped_ptr.h" |
| 12 #include "base/memory/weak_ptr.h" | 12 #include "base/memory/weak_ptr.h" |
| 13 #include "base/task.h" | 13 #include "base/message_loop_helpers.h" |
| 14 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPlugin.h" | 14 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPlugin.h" |
| 15 #include "ui/gfx/rect.h" | 15 #include "ui/gfx/rect.h" |
| 16 #include "webkit/plugins/webkit_plugins_export.h" | 16 #include "webkit/plugins/webkit_plugins_export.h" |
| 17 | 17 |
| 18 namespace WebKit { | 18 namespace WebKit { |
| 19 struct WebPluginParams; | 19 struct WebPluginParams; |
| 20 } | 20 } |
| 21 | 21 |
| 22 namespace webkit { | 22 namespace webkit { |
| 23 namespace ppapi { | 23 namespace ppapi { |
| 24 | 24 |
| 25 class PluginDelegate; | 25 class PluginDelegate; |
| 26 class PluginInstance; | 26 class PluginInstance; |
| 27 class PluginModule; | 27 class PluginModule; |
| 28 class PPB_URLLoader_Impl; | 28 class PPB_URLLoader_Impl; |
| 29 | 29 |
| 30 class WebPluginImpl : public WebKit::WebPlugin { | 30 class WebPluginImpl : public WebKit::WebPlugin { |
| 31 public: | 31 public: |
| 32 WEBKIT_PLUGINS_EXPORT WebPluginImpl( | 32 WEBKIT_PLUGINS_EXPORT WebPluginImpl( |
| 33 PluginModule* module, | 33 PluginModule* module, |
| 34 const WebKit::WebPluginParams& params, | 34 const WebKit::WebPluginParams& params, |
| 35 const base::WeakPtr<PluginDelegate>& plugin_delegate); | 35 const base::WeakPtr<PluginDelegate>& plugin_delegate); |
| 36 | 36 |
| 37 private: | 37 private: |
| 38 friend class DeleteTask<WebPluginImpl>; | 38 friend class base::DeleteHelper<WebPluginImpl>; |
| 39 | 39 |
| 40 WEBKIT_PLUGINS_EXPORT virtual ~WebPluginImpl(); | 40 WEBKIT_PLUGINS_EXPORT virtual ~WebPluginImpl(); |
| 41 | 41 |
| 42 // WebKit::WebPlugin implementation. | 42 // WebKit::WebPlugin implementation. |
| 43 virtual bool initialize(WebKit::WebPluginContainer* container); | 43 virtual bool initialize(WebKit::WebPluginContainer* container); |
| 44 virtual void destroy(); | 44 virtual void destroy(); |
| 45 virtual NPObject* scriptableObject(); | 45 virtual NPObject* scriptableObject(); |
| 46 virtual bool getFormValue(WebKit::WebString& value); | 46 virtual bool getFormValue(WebKit::WebString& value); |
| 47 virtual void paint(WebKit::WebCanvas* canvas, const WebKit::WebRect& rect); | 47 virtual void paint(WebKit::WebCanvas* canvas, const WebKit::WebRect& rect); |
| 48 virtual void updateGeometry( | 48 virtual void updateGeometry( |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 91 scoped_refptr<PPB_URLLoader_Impl> document_loader_; | 91 scoped_refptr<PPB_URLLoader_Impl> document_loader_; |
| 92 gfx::Rect plugin_rect_; | 92 gfx::Rect plugin_rect_; |
| 93 | 93 |
| 94 DISALLOW_COPY_AND_ASSIGN(WebPluginImpl); | 94 DISALLOW_COPY_AND_ASSIGN(WebPluginImpl); |
| 95 }; | 95 }; |
| 96 | 96 |
| 97 } // namespace ppapi | 97 } // namespace ppapi |
| 98 } // namespace webkit | 98 } // namespace webkit |
| 99 | 99 |
| 100 #endif // WEBKIT_PLUGINS_PPAPI_PPAPI_WEBPLUGIN_IMPL_H_ | 100 #endif // WEBKIT_PLUGINS_PPAPI_PPAPI_WEBPLUGIN_IMPL_H_ |
| OLD | NEW |