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_RESOURCE_CREATION_IMPL_H_ | 5 #ifndef WEBKIT_PLUGINS_PPAPI_RESOURCE_CREATION_IMPL_H_ |
6 #define WEBKIT_PLUGINS_PPAPI_RESOURCE_CREATION_IMPL_H_ | 6 #define WEBKIT_PLUGINS_PPAPI_RESOURCE_CREATION_IMPL_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "ppapi/shared_impl/function_group_base.h" | 10 #include "ppapi/shared_impl/function_group_base.h" |
11 #include "ppapi/thunk/resource_creation_api.h" | 11 #include "ppapi/thunk/resource_creation_api.h" |
12 | 12 |
13 namespace webkit { | 13 namespace webkit { |
14 namespace ppapi { | 14 namespace ppapi { |
15 | 15 |
16 class PluginInstance; | 16 class PluginInstance; |
17 | 17 |
18 class ResourceCreationImpl : public ::ppapi::FunctionGroupBase, | 18 class ResourceCreationImpl : public ::ppapi::FunctionGroupBase, |
19 public ::ppapi::thunk::ResourceCreationAPI { | 19 public ::ppapi::thunk::ResourceCreationAPI { |
20 public: | 20 public: |
21 ResourceCreationImpl(PluginInstance* instance); | 21 explicit ResourceCreationImpl(PluginInstance* instance); |
22 virtual ~ResourceCreationImpl(); | 22 virtual ~ResourceCreationImpl(); |
23 | 23 |
24 // FunctionGroupBase implementation. | 24 // FunctionGroupBase implementation. |
25 virtual ::ppapi::thunk::ResourceCreationAPI* AsResourceCreationAPI(); | 25 virtual ::ppapi::thunk::ResourceCreationAPI* AsResourceCreationAPI(); |
26 | 26 |
27 // ResourceCreationAPI implementation. | 27 // ResourceCreationAPI implementation. |
28 virtual PP_Resource CreateAudio(PP_Instance instance, | 28 virtual PP_Resource CreateAudio(PP_Instance instance, |
29 PP_Resource config_id, | 29 PP_Resource config_id, |
30 PPB_Audio_Callback audio_callback, | 30 PPB_Audio_Callback audio_callback, |
31 void* user_data) OVERRIDE; | 31 void* user_data) OVERRIDE; |
(...skipping 13 matching lines...) Expand all Loading... |
45 PP_Resource share_context, | 45 PP_Resource share_context, |
46 const int32_t* attrib_list) OVERRIDE; | 46 const int32_t* attrib_list) OVERRIDE; |
47 virtual PP_Resource CreateDirectoryReader(PP_Resource directory_ref) OVERRIDE; | 47 virtual PP_Resource CreateDirectoryReader(PP_Resource directory_ref) OVERRIDE; |
48 virtual PP_Resource CreateFileChooser( | 48 virtual PP_Resource CreateFileChooser( |
49 PP_Instance instance, | 49 PP_Instance instance, |
50 const PP_FileChooserOptions_Dev* options) OVERRIDE; | 50 const PP_FileChooserOptions_Dev* options) OVERRIDE; |
51 virtual PP_Resource CreateFileIO(PP_Instance instance) OVERRIDE; | 51 virtual PP_Resource CreateFileIO(PP_Instance instance) OVERRIDE; |
52 virtual PP_Resource CreateFileRef(PP_Resource file_system, | 52 virtual PP_Resource CreateFileRef(PP_Resource file_system, |
53 const char* path) OVERRIDE; | 53 const char* path) OVERRIDE; |
54 virtual PP_Resource CreateFileSystem(PP_Instance instance, | 54 virtual PP_Resource CreateFileSystem(PP_Instance instance, |
55 PP_FileSystemType_Dev type) OVERRIDE; | 55 PP_FileSystemType type) OVERRIDE; |
56 virtual PP_Resource CreateFlashMenu(PP_Instance instance, | 56 virtual PP_Resource CreateFlashMenu(PP_Instance instance, |
57 const PP_Flash_Menu* menu_data) OVERRIDE; | 57 const PP_Flash_Menu* menu_data) OVERRIDE; |
58 virtual PP_Resource CreateFlashNetConnector(PP_Instance instance) OVERRIDE; | 58 virtual PP_Resource CreateFlashNetConnector(PP_Instance instance) OVERRIDE; |
59 virtual PP_Resource CreateFlashTCPSocket(PP_Instance instance) OVERRIDE; | 59 virtual PP_Resource CreateFlashTCPSocket(PP_Instance instance) OVERRIDE; |
60 virtual PP_Resource CreateFontObject( | 60 virtual PP_Resource CreateFontObject( |
61 PP_Instance instance, | 61 PP_Instance instance, |
62 const PP_FontDescription_Dev* description) OVERRIDE; | 62 const PP_FontDescription_Dev* description) OVERRIDE; |
63 virtual PP_Resource CreateGraphics2D(PP_Instance pp_instance, | 63 virtual PP_Resource CreateGraphics2D(PP_Instance pp_instance, |
64 const PP_Size& size, | 64 const PP_Size& size, |
65 PP_Bool is_always_opaque) OVERRIDE; | 65 PP_Bool is_always_opaque) OVERRIDE; |
(...skipping 22 matching lines...) Expand all Loading... |
88 private: | 88 private: |
89 PluginInstance* instance_; | 89 PluginInstance* instance_; |
90 | 90 |
91 DISALLOW_COPY_AND_ASSIGN(ResourceCreationImpl); | 91 DISALLOW_COPY_AND_ASSIGN(ResourceCreationImpl); |
92 }; | 92 }; |
93 | 93 |
94 } // namespace ppapi | 94 } // namespace ppapi |
95 } // namespace webkit | 95 } // namespace webkit |
96 | 96 |
97 #endif // WEBKIT_PLUGINS_PPAPI_RESOURCE_CREATION_IMPL_H_ | 97 #endif // WEBKIT_PLUGINS_PPAPI_RESOURCE_CREATION_IMPL_H_ |
OLD | NEW |