| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_GLUE_PLUGINS_PEPPER_PLUGIN_INSTANCE_H_ | 5 #ifndef WEBKIT_GLUE_PLUGINS_PEPPER_PLUGIN_INSTANCE_H_ |
| 6 #define WEBKIT_GLUE_PLUGINS_PEPPER_PLUGIN_INSTANCE_H_ | 6 #define WEBKIT_GLUE_PLUGINS_PEPPER_PLUGIN_INSTANCE_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 struct WebCursorInfo; | 27 struct WebCursorInfo; |
| 28 class WebInputEvent; | 28 class WebInputEvent; |
| 29 class WebPluginContainer; | 29 class WebPluginContainer; |
| 30 } | 30 } |
| 31 | 31 |
| 32 namespace pepper { | 32 namespace pepper { |
| 33 | 33 |
| 34 class DeviceContext2D; | 34 class DeviceContext2D; |
| 35 class PluginDelegate; | 35 class PluginDelegate; |
| 36 class PluginModule; | 36 class PluginModule; |
| 37 class URLLoader; |
| 37 | 38 |
| 38 class PluginInstance : public base::RefCounted<PluginInstance> { | 39 class PluginInstance : public base::RefCounted<PluginInstance> { |
| 39 public: | 40 public: |
| 40 PluginInstance(PluginDelegate* delegate, | 41 PluginInstance(PluginDelegate* delegate, |
| 41 PluginModule* module, | 42 PluginModule* module, |
| 42 const PPP_Instance* instance_interface); | 43 const PPP_Instance* instance_interface); |
| 43 ~PluginInstance(); | 44 ~PluginInstance(); |
| 44 | 45 |
| 45 static const PPB_Instance* GetInterface(); | 46 static const PPB_Instance* GetInterface(); |
| 46 | 47 |
| (...skipping 24 matching lines...) Expand all Loading... |
| 71 // PPB_Instance implementation. | 72 // PPB_Instance implementation. |
| 72 PP_Var GetWindowObject(); | 73 PP_Var GetWindowObject(); |
| 73 PP_Var GetOwnerElementObject(); | 74 PP_Var GetOwnerElementObject(); |
| 74 bool BindGraphicsDeviceContext(PP_Resource device_id); | 75 bool BindGraphicsDeviceContext(PP_Resource device_id); |
| 75 | 76 |
| 76 // PPP_Instance pass-through. | 77 // PPP_Instance pass-through. |
| 77 void Delete(); | 78 void Delete(); |
| 78 bool Initialize(WebKit::WebPluginContainer* container, | 79 bool Initialize(WebKit::WebPluginContainer* container, |
| 79 const std::vector<std::string>& arg_names, | 80 const std::vector<std::string>& arg_names, |
| 80 const std::vector<std::string>& arg_values); | 81 const std::vector<std::string>& arg_values); |
| 82 bool HandleDocumentLoad(URLLoader* loader); |
| 81 bool HandleInputEvent(const WebKit::WebInputEvent& event, | 83 bool HandleInputEvent(const WebKit::WebInputEvent& event, |
| 82 WebKit::WebCursorInfo* cursor_info); | 84 WebKit::WebCursorInfo* cursor_info); |
| 83 PP_Var GetInstanceObject(); | 85 PP_Var GetInstanceObject(); |
| 84 void ViewChanged(const gfx::Rect& position, const gfx::Rect& clip); | 86 void ViewChanged(const gfx::Rect& position, const gfx::Rect& clip); |
| 85 | 87 |
| 86 // Notifications that the view has rendered the page and that it has been | 88 // Notifications that the view has rendered the page and that it has been |
| 87 // flushed to the screen. These messages are used to send Flush callbacks to | 89 // flushed to the screen. These messages are used to send Flush callbacks to |
| 88 // the plugin for DeviceContext2D. | 90 // the plugin for DeviceContext2D. |
| 89 void ViewInitiatedPaint(); | 91 void ViewInitiatedPaint(); |
| 90 void ViewFlushedPaint(); | 92 void ViewFlushedPaint(); |
| (...skipping 18 matching lines...) Expand all Loading... |
| 109 | 111 |
| 110 // The current device context for painting in 2D. | 112 // The current device context for painting in 2D. |
| 111 scoped_refptr<DeviceContext2D> device_context_2d_; | 113 scoped_refptr<DeviceContext2D> device_context_2d_; |
| 112 | 114 |
| 113 DISALLOW_COPY_AND_ASSIGN(PluginInstance); | 115 DISALLOW_COPY_AND_ASSIGN(PluginInstance); |
| 114 }; | 116 }; |
| 115 | 117 |
| 116 } // namespace pepper | 118 } // namespace pepper |
| 117 | 119 |
| 118 #endif // WEBKIT_GLUE_PLUGINS_PEPPER_PLUGIN_INSTANCE_H_ | 120 #endif // WEBKIT_GLUE_PLUGINS_PEPPER_PLUGIN_INSTANCE_H_ |
| OLD | NEW |