| 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_PPAPI_PPB_GRAPHICS_2D_IMPL_H_ | 5 #ifndef WEBKIT_PLUGINS_PPAPI_PPB_GRAPHICS_2D_IMPL_H_ |
| 6 #define WEBKIT_PLUGINS_PPAPI_PPB_GRAPHICS_2D_IMPL_H_ | 6 #define WEBKIT_PLUGINS_PPAPI_PPB_GRAPHICS_2D_IMPL_H_ |
| 7 | 7 |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 42 virtual void LastPluginRefWasDeleted() OVERRIDE; | 42 virtual void LastPluginRefWasDeleted() OVERRIDE; |
| 43 | 43 |
| 44 // PPB_Graphics2D functions. | 44 // PPB_Graphics2D functions. |
| 45 virtual PP_Bool Describe(PP_Size* size, PP_Bool* is_always_opaque) OVERRIDE; | 45 virtual PP_Bool Describe(PP_Size* size, PP_Bool* is_always_opaque) OVERRIDE; |
| 46 virtual void PaintImageData(PP_Resource image_data, | 46 virtual void PaintImageData(PP_Resource image_data, |
| 47 const PP_Point* top_left, | 47 const PP_Point* top_left, |
| 48 const PP_Rect* src_rect) OVERRIDE; | 48 const PP_Rect* src_rect) OVERRIDE; |
| 49 virtual void Scroll(const PP_Rect* clip_rect, | 49 virtual void Scroll(const PP_Rect* clip_rect, |
| 50 const PP_Point* amount) OVERRIDE; | 50 const PP_Point* amount) OVERRIDE; |
| 51 virtual void ReplaceContents(PP_Resource image_data) OVERRIDE; | 51 virtual void ReplaceContents(PP_Resource image_data) OVERRIDE; |
| 52 virtual int32_t Flush(PP_CompletionCallback callback) OVERRIDE; | 52 virtual int32_t Flush( |
| 53 scoped_refptr< ::ppapi::TrackedCallback> callback) OVERRIDE; |
| 53 | 54 |
| 54 bool ReadImageData(PP_Resource image, const PP_Point* top_left); | 55 bool ReadImageData(PP_Resource image, const PP_Point* top_left); |
| 55 | 56 |
| 56 // Assciates this device with the given plugin instance. You can pass NULL to | 57 // Assciates this device with the given plugin instance. You can pass NULL to |
| 57 // clear the existing device. Returns true on success. In this case, a | 58 // clear the existing device. Returns true on success. In this case, a |
| 58 // repaint of the page will also be scheduled. Failure means that the device | 59 // repaint of the page will also be scheduled. Failure means that the device |
| 59 // is already bound to a different instance, and nothing will happen. | 60 // is already bound to a different instance, and nothing will happen. |
| 60 bool BindToInstance(PluginInstance* new_instance); | 61 bool BindToInstance(PluginInstance* new_instance); |
| 61 | 62 |
| 62 // Paints the current backing store to the web page. | 63 // Paints the current backing store to the web page. |
| (...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 186 | 187 |
| 187 base::WeakPtrFactory<PPB_Graphics2D_Impl> weak_ptr_factory_; | 188 base::WeakPtrFactory<PPB_Graphics2D_Impl> weak_ptr_factory_; |
| 188 | 189 |
| 189 DISALLOW_COPY_AND_ASSIGN(PPB_Graphics2D_Impl); | 190 DISALLOW_COPY_AND_ASSIGN(PPB_Graphics2D_Impl); |
| 190 }; | 191 }; |
| 191 | 192 |
| 192 } // namespace ppapi | 193 } // namespace ppapi |
| 193 } // namespace webkit | 194 } // namespace webkit |
| 194 | 195 |
| 195 #endif // WEBKIT_PLUGINS_PPAPI_PPB_GRAPHICS_2D_IMPL_H_ | 196 #endif // WEBKIT_PLUGINS_PPAPI_PPB_GRAPHICS_2D_IMPL_H_ |
| OLD | NEW |