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_FLASH_IMPL_H_ | 5 #ifndef WEBKIT_PLUGINS_PPAPI_PPB_FLASH_IMPL_H_ |
6 #define WEBKIT_PLUGINS_PPAPI_PPB_FLASH_IMPL_H_ | 6 #define WEBKIT_PLUGINS_PPAPI_PPB_FLASH_IMPL_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/compiler_specific.h" | |
9 #include "build/build_config.h" | 10 #include "build/build_config.h" |
10 #include "ppapi/c/pp_point.h" | 11 #include "ppapi/thunk/ppb_flash_api.h" |
11 #include "ppapi/c/pp_rect.h" | |
12 #include "ppapi/c/private/ppb_flash.h" | |
13 | 12 |
14 namespace webkit { | 13 namespace webkit { |
15 namespace ppapi { | 14 namespace ppapi { |
16 | 15 |
17 class PPB_Flash_Impl { | 16 class PluginInstance; |
17 | |
18 class PPB_Flash_Impl : public ::ppapi::thunk::PPB_Flash_API { | |
18 public: | 19 public: |
19 // Returns a pointer to the interface implementing PPB_Flash that is | 20 PPB_Flash_Impl(PluginInstance* instance); |
yzshen1
2012/04/18 17:57:22
explicit, please.
| |
20 // exposed to the plugin. | 21 virtual ~PPB_Flash_Impl(); |
21 static const PPB_Flash_11* GetInterface11(); | 22 |
22 static const PPB_Flash_12_0* GetInterface12_0(); | 23 // PPB_Flash_API. |
23 static const PPB_Flash_12_1* GetInterface12_1(); | 24 virtual void SetInstanceAlwaysOnTop(PP_Instance instance, |
24 static const PPB_Flash_12_2* GetInterface12_2(); | 25 PP_Bool on_top) OVERRIDE; |
26 virtual PP_Bool DrawGlyphs(PP_Instance instance, | |
27 PP_Resource pp_image_data, | |
28 const PP_FontDescription_Dev* font_desc, | |
29 uint32_t color, | |
30 const PP_Point* position, | |
31 const PP_Rect* clip, | |
32 const float transformation[3][3], | |
33 PP_Bool allow_subpixel_aa, | |
34 uint32_t glyph_count, | |
35 const uint16_t glyph_indices[], | |
36 const PP_Point glyph_advances[]) OVERRIDE; | |
37 virtual PP_Var GetProxyForURL(PP_Instance instance, const char* url) OVERRIDE; | |
38 virtual int32_t Navigate(PP_Instance instance, | |
39 PP_Resource request_info, | |
40 const char* target, | |
41 PP_Bool from_user_action) OVERRIDE; | |
42 virtual void RunMessageLoop(PP_Instance instance) OVERRIDE; | |
43 virtual void QuitMessageLoop(PP_Instance instance) OVERRIDE; | |
44 virtual double GetLocalTimeZoneOffset(PP_Instance instance, | |
45 PP_Time t) OVERRIDE; | |
46 virtual PP_Bool IsRectTopmost(PP_Instance instance, | |
47 const PP_Rect* rect) OVERRIDE; | |
48 virtual int32_t InvokePrinting(PP_Instance instance) OVERRIDE; | |
49 virtual void UpdateActivity(PP_Instance instance) OVERRIDE; | |
50 virtual PP_Var GetDeviceID(PP_Instance instance) OVERRIDE; | |
51 virtual PP_Bool FlashIsFullscreen(PP_Instance instance) OVERRIDE; | |
52 virtual PP_Bool FlashSetFullscreen(PP_Instance instance, | |
53 PP_Bool fullscreen) OVERRIDE; | |
54 virtual PP_Bool FlashGetScreenSize(PP_Instance instance, | |
55 PP_Size* size) OVERRIDE; | |
25 | 56 |
26 private: | 57 private: |
58 PluginInstance* instance_; | |
59 | |
27 DISALLOW_COPY_AND_ASSIGN(PPB_Flash_Impl); | 60 DISALLOW_COPY_AND_ASSIGN(PPB_Flash_Impl); |
28 }; | 61 }; |
29 | 62 |
30 } // namespace ppapi | 63 } // namespace ppapi |
31 } // namespace webkit | 64 } // namespace webkit |
32 | 65 |
33 #endif // WEBKIT_PLUGINS_PPAPI_PPB_FLASH_IMPL_H_ | 66 #endif // WEBKIT_PLUGINS_PPAPI_PPB_FLASH_IMPL_H_ |
OLD | NEW |