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 PPAPI_PROXY_RESOURCE_CREATION_PROXY_H_ | 5 #ifndef PPAPI_PROXY_RESOURCE_CREATION_PROXY_H_ |
6 #define PPAPI_PROXY_RESOURCE_CREATION_PROXY_H_ | 6 #define PPAPI_PROXY_RESOURCE_CREATION_PROXY_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 19 matching lines...) Expand all Loading... |
30 public thunk::ResourceCreationAPI { | 30 public thunk::ResourceCreationAPI { |
31 public: | 31 public: |
32 explicit ResourceCreationProxy(Dispatcher* dispatcher); | 32 explicit ResourceCreationProxy(Dispatcher* dispatcher); |
33 virtual ~ResourceCreationProxy(); | 33 virtual ~ResourceCreationProxy(); |
34 | 34 |
35 // Factory function used for registration (normal code can just use the | 35 // Factory function used for registration (normal code can just use the |
36 // constructor). | 36 // constructor). |
37 static InterfaceProxy* Create(Dispatcher* dispatcher); | 37 static InterfaceProxy* Create(Dispatcher* dispatcher); |
38 | 38 |
39 // ResourceCreationAPI (called in plugin). | 39 // ResourceCreationAPI (called in plugin). |
40 virtual PP_Resource CreateFileIO(PP_Instance instance) OVERRIDE; | 40 virtual PP_Resource CreateFileIO(PP_Instance instance) override; |
41 virtual PP_Resource CreateFileRef( | 41 virtual PP_Resource CreateFileRef( |
42 PP_Instance instance, | 42 PP_Instance instance, |
43 const FileRefCreateInfo& create_info) OVERRIDE; | 43 const FileRefCreateInfo& create_info) override; |
44 virtual PP_Resource CreateFileSystem(PP_Instance instance, | 44 virtual PP_Resource CreateFileSystem(PP_Instance instance, |
45 PP_FileSystemType type) OVERRIDE; | 45 PP_FileSystemType type) override; |
46 virtual PP_Resource CreateIMEInputEvent(PP_Instance instance, | 46 virtual PP_Resource CreateIMEInputEvent(PP_Instance instance, |
47 PP_InputEvent_Type type, | 47 PP_InputEvent_Type type, |
48 PP_TimeTicks time_stamp, | 48 PP_TimeTicks time_stamp, |
49 struct PP_Var text, | 49 struct PP_Var text, |
50 uint32_t segment_number, | 50 uint32_t segment_number, |
51 const uint32_t* segment_offsets, | 51 const uint32_t* segment_offsets, |
52 int32_t target_segment, | 52 int32_t target_segment, |
53 uint32_t selection_start, | 53 uint32_t selection_start, |
54 uint32_t selection_end) OVERRIDE; | 54 uint32_t selection_end) override; |
55 virtual PP_Resource CreateKeyboardInputEvent_1_0( | 55 virtual PP_Resource CreateKeyboardInputEvent_1_0( |
56 PP_Instance instance, | 56 PP_Instance instance, |
57 PP_InputEvent_Type type, | 57 PP_InputEvent_Type type, |
58 PP_TimeTicks time_stamp, | 58 PP_TimeTicks time_stamp, |
59 uint32_t modifiers, | 59 uint32_t modifiers, |
60 uint32_t key_code, | 60 uint32_t key_code, |
61 PP_Var character_text) OVERRIDE; | 61 PP_Var character_text) override; |
62 virtual PP_Resource CreateKeyboardInputEvent_1_2( | 62 virtual PP_Resource CreateKeyboardInputEvent_1_2( |
63 PP_Instance instance, | 63 PP_Instance instance, |
64 PP_InputEvent_Type type, | 64 PP_InputEvent_Type type, |
65 PP_TimeTicks time_stamp, | 65 PP_TimeTicks time_stamp, |
66 uint32_t modifiers, | 66 uint32_t modifiers, |
67 uint32_t key_code, | 67 uint32_t key_code, |
68 PP_Var character_text, | 68 PP_Var character_text, |
69 PP_Var code) OVERRIDE; | 69 PP_Var code) override; |
70 virtual PP_Resource CreateMouseInputEvent( | 70 virtual PP_Resource CreateMouseInputEvent( |
71 PP_Instance instance, | 71 PP_Instance instance, |
72 PP_InputEvent_Type type, | 72 PP_InputEvent_Type type, |
73 PP_TimeTicks time_stamp, | 73 PP_TimeTicks time_stamp, |
74 uint32_t modifiers, | 74 uint32_t modifiers, |
75 PP_InputEvent_MouseButton mouse_button, | 75 PP_InputEvent_MouseButton mouse_button, |
76 const PP_Point* mouse_position, | 76 const PP_Point* mouse_position, |
77 int32_t click_count, | 77 int32_t click_count, |
78 const PP_Point* mouse_movement) OVERRIDE; | 78 const PP_Point* mouse_movement) override; |
79 virtual PP_Resource CreateTouchInputEvent( | 79 virtual PP_Resource CreateTouchInputEvent( |
80 PP_Instance instance, | 80 PP_Instance instance, |
81 PP_InputEvent_Type type, | 81 PP_InputEvent_Type type, |
82 PP_TimeTicks time_stamp, | 82 PP_TimeTicks time_stamp, |
83 uint32_t modifiers) OVERRIDE; | 83 uint32_t modifiers) override; |
84 virtual PP_Resource CreateTrueTypeFont( | 84 virtual PP_Resource CreateTrueTypeFont( |
85 PP_Instance instance, | 85 PP_Instance instance, |
86 const PP_TrueTypeFontDesc_Dev* desc) OVERRIDE; | 86 const PP_TrueTypeFontDesc_Dev* desc) override; |
87 virtual PP_Resource CreateURLLoader(PP_Instance instance) OVERRIDE; | 87 virtual PP_Resource CreateURLLoader(PP_Instance instance) override; |
88 virtual PP_Resource CreateURLRequestInfo( | 88 virtual PP_Resource CreateURLRequestInfo( |
89 PP_Instance instance) OVERRIDE; | 89 PP_Instance instance) override; |
90 virtual PP_Resource CreateWheelInputEvent( | 90 virtual PP_Resource CreateWheelInputEvent( |
91 PP_Instance instance, | 91 PP_Instance instance, |
92 PP_TimeTicks time_stamp, | 92 PP_TimeTicks time_stamp, |
93 uint32_t modifiers, | 93 uint32_t modifiers, |
94 const PP_FloatPoint* wheel_delta, | 94 const PP_FloatPoint* wheel_delta, |
95 const PP_FloatPoint* wheel_ticks, | 95 const PP_FloatPoint* wheel_ticks, |
96 PP_Bool scroll_by_page) OVERRIDE; | 96 PP_Bool scroll_by_page) override; |
97 virtual PP_Resource CreateAudio1_0(PP_Instance instance, | 97 virtual PP_Resource CreateAudio1_0(PP_Instance instance, |
98 PP_Resource config_id, | 98 PP_Resource config_id, |
99 PPB_Audio_Callback_1_0 audio_callback, | 99 PPB_Audio_Callback_1_0 audio_callback, |
100 void* user_data) OVERRIDE; | 100 void* user_data) override; |
101 virtual PP_Resource CreateAudio(PP_Instance instance, | 101 virtual PP_Resource CreateAudio(PP_Instance instance, |
102 PP_Resource config_id, | 102 PP_Resource config_id, |
103 PPB_Audio_Callback audio_callback, | 103 PPB_Audio_Callback audio_callback, |
104 void* user_data) OVERRIDE; | 104 void* user_data) override; |
105 virtual PP_Resource CreateAudioTrusted(PP_Instance instance) OVERRIDE; | 105 virtual PP_Resource CreateAudioTrusted(PP_Instance instance) override; |
106 virtual PP_Resource CreateAudioConfig(PP_Instance instance, | 106 virtual PP_Resource CreateAudioConfig(PP_Instance instance, |
107 PP_AudioSampleRate sample_rate, | 107 PP_AudioSampleRate sample_rate, |
108 uint32_t sample_frame_count) OVERRIDE; | 108 uint32_t sample_frame_count) override; |
109 virtual PP_Resource CreateCompositor(PP_Instance instance) OVERRIDE; | 109 virtual PP_Resource CreateCompositor(PP_Instance instance) override; |
110 virtual PP_Resource CreateFileChooser(PP_Instance instance, | 110 virtual PP_Resource CreateFileChooser(PP_Instance instance, |
111 PP_FileChooserMode_Dev mode, | 111 PP_FileChooserMode_Dev mode, |
112 const PP_Var& accept_types) OVERRIDE; | 112 const PP_Var& accept_types) override; |
113 virtual PP_Resource CreateGraphics2D(PP_Instance pp_instance, | 113 virtual PP_Resource CreateGraphics2D(PP_Instance pp_instance, |
114 const PP_Size* size, | 114 const PP_Size* size, |
115 PP_Bool is_always_opaque) OVERRIDE; | 115 PP_Bool is_always_opaque) override; |
116 virtual PP_Resource CreateGraphics3D(PP_Instance instance, | 116 virtual PP_Resource CreateGraphics3D(PP_Instance instance, |
117 PP_Resource share_context, | 117 PP_Resource share_context, |
118 const int32_t* attrib_list) OVERRIDE; | 118 const int32_t* attrib_list) override; |
119 virtual PP_Resource CreateGraphics3DRaw( | 119 virtual PP_Resource CreateGraphics3DRaw( |
120 PP_Instance instance, | 120 PP_Instance instance, |
121 PP_Resource share_context, | 121 PP_Resource share_context, |
122 const int32_t* attrib_list, | 122 const int32_t* attrib_list, |
123 base::SharedMemoryHandle* shared_state) OVERRIDE; | 123 base::SharedMemoryHandle* shared_state) override; |
124 virtual PP_Resource CreateHostResolver(PP_Instance instance) OVERRIDE; | 124 virtual PP_Resource CreateHostResolver(PP_Instance instance) override; |
125 virtual PP_Resource CreateHostResolverPrivate(PP_Instance instance) OVERRIDE; | 125 virtual PP_Resource CreateHostResolverPrivate(PP_Instance instance) override; |
126 virtual PP_Resource CreateImageData(PP_Instance instance, | 126 virtual PP_Resource CreateImageData(PP_Instance instance, |
127 PP_ImageDataFormat format, | 127 PP_ImageDataFormat format, |
128 const PP_Size* size, | 128 const PP_Size* size, |
129 PP_Bool init_to_zero) OVERRIDE; | 129 PP_Bool init_to_zero) override; |
130 virtual PP_Resource CreateImageDataSimple(PP_Instance instance, | 130 virtual PP_Resource CreateImageDataSimple(PP_Instance instance, |
131 PP_ImageDataFormat format, | 131 PP_ImageDataFormat format, |
132 const PP_Size* size, | 132 const PP_Size* size, |
133 PP_Bool init_to_zero) OVERRIDE; | 133 PP_Bool init_to_zero) override; |
134 virtual PP_Resource CreateMediaStreamVideoTrack( | 134 virtual PP_Resource CreateMediaStreamVideoTrack( |
135 PP_Instance instance) OVERRIDE; | 135 PP_Instance instance) override; |
136 virtual PP_Resource CreateNetAddressFromIPv4Address( | 136 virtual PP_Resource CreateNetAddressFromIPv4Address( |
137 PP_Instance instance, | 137 PP_Instance instance, |
138 const PP_NetAddress_IPv4* ipv4_addr) OVERRIDE; | 138 const PP_NetAddress_IPv4* ipv4_addr) override; |
139 virtual PP_Resource CreateNetAddressFromIPv6Address( | 139 virtual PP_Resource CreateNetAddressFromIPv6Address( |
140 PP_Instance instance, | 140 PP_Instance instance, |
141 const PP_NetAddress_IPv6* ipv6_addr) OVERRIDE; | 141 const PP_NetAddress_IPv6* ipv6_addr) override; |
142 virtual PP_Resource CreateNetAddressFromNetAddressPrivate( | 142 virtual PP_Resource CreateNetAddressFromNetAddressPrivate( |
143 PP_Instance instance, | 143 PP_Instance instance, |
144 const PP_NetAddress_Private& private_addr) OVERRIDE; | 144 const PP_NetAddress_Private& private_addr) override; |
145 virtual PP_Resource CreateNetworkMonitor(PP_Instance instance) OVERRIDE; | 145 virtual PP_Resource CreateNetworkMonitor(PP_Instance instance) override; |
146 virtual PP_Resource CreateOutputProtectionPrivate( | 146 virtual PP_Resource CreateOutputProtectionPrivate( |
147 PP_Instance instance) OVERRIDE; | 147 PP_Instance instance) override; |
148 virtual PP_Resource CreatePrinting(PP_Instance) OVERRIDE; | 148 virtual PP_Resource CreatePrinting(PP_Instance) override; |
149 virtual PP_Resource CreateTCPServerSocketPrivate( | 149 virtual PP_Resource CreateTCPServerSocketPrivate( |
150 PP_Instance instance) OVERRIDE; | 150 PP_Instance instance) override; |
151 virtual PP_Resource CreateTCPSocket1_0(PP_Instance instance) OVERRIDE; | 151 virtual PP_Resource CreateTCPSocket1_0(PP_Instance instance) override; |
152 virtual PP_Resource CreateTCPSocket(PP_Instance instance) OVERRIDE; | 152 virtual PP_Resource CreateTCPSocket(PP_Instance instance) override; |
153 virtual PP_Resource CreateTCPSocketPrivate(PP_Instance instance) OVERRIDE; | 153 virtual PP_Resource CreateTCPSocketPrivate(PP_Instance instance) override; |
154 virtual PP_Resource CreateUDPSocket(PP_Instance instance) OVERRIDE; | 154 virtual PP_Resource CreateUDPSocket(PP_Instance instance) override; |
155 virtual PP_Resource CreateUDPSocketPrivate(PP_Instance instance) OVERRIDE; | 155 virtual PP_Resource CreateUDPSocketPrivate(PP_Instance instance) override; |
156 virtual PP_Resource CreateVideoDecoder(PP_Instance instance) OVERRIDE; | 156 virtual PP_Resource CreateVideoDecoder(PP_Instance instance) override; |
157 virtual PP_Resource CreateVideoDestination(PP_Instance instance) OVERRIDE; | 157 virtual PP_Resource CreateVideoDestination(PP_Instance instance) override; |
158 virtual PP_Resource CreateVideoSource(PP_Instance instance) OVERRIDE; | 158 virtual PP_Resource CreateVideoSource(PP_Instance instance) override; |
159 virtual PP_Resource CreateWebSocket(PP_Instance instance) OVERRIDE; | 159 virtual PP_Resource CreateWebSocket(PP_Instance instance) override; |
160 virtual PP_Resource CreateX509CertificatePrivate( | 160 virtual PP_Resource CreateX509CertificatePrivate( |
161 PP_Instance instance) OVERRIDE; | 161 PP_Instance instance) override; |
162 #if !defined(OS_NACL) | 162 #if !defined(OS_NACL) |
163 virtual PP_Resource CreateAudioInput(PP_Instance instance) OVERRIDE; | 163 virtual PP_Resource CreateAudioInput(PP_Instance instance) override; |
164 virtual PP_Resource CreateBroker(PP_Instance instance) OVERRIDE; | 164 virtual PP_Resource CreateBroker(PP_Instance instance) override; |
165 virtual PP_Resource CreateBrowserFont( | 165 virtual PP_Resource CreateBrowserFont( |
166 PP_Instance instance, | 166 PP_Instance instance, |
167 const PP_BrowserFont_Trusted_Description* description) OVERRIDE; | 167 const PP_BrowserFont_Trusted_Description* description) override; |
168 virtual PP_Resource CreateBuffer(PP_Instance instance, | 168 virtual PP_Resource CreateBuffer(PP_Instance instance, |
169 uint32_t size) OVERRIDE; | 169 uint32_t size) override; |
170 virtual PP_Resource CreateFlashDRM(PP_Instance instance) OVERRIDE; | 170 virtual PP_Resource CreateFlashDRM(PP_Instance instance) override; |
171 virtual PP_Resource CreateFlashFontFile( | 171 virtual PP_Resource CreateFlashFontFile( |
172 PP_Instance instance, | 172 PP_Instance instance, |
173 const PP_BrowserFont_Trusted_Description* description, | 173 const PP_BrowserFont_Trusted_Description* description, |
174 PP_PrivateFontCharset charset) OVERRIDE; | 174 PP_PrivateFontCharset charset) override; |
175 virtual PP_Resource CreateFlashMenu(PP_Instance instance, | 175 virtual PP_Resource CreateFlashMenu(PP_Instance instance, |
176 const PP_Flash_Menu* menu_data) OVERRIDE; | 176 const PP_Flash_Menu* menu_data) override; |
177 virtual PP_Resource CreateFlashMessageLoop(PP_Instance instance) OVERRIDE; | 177 virtual PP_Resource CreateFlashMessageLoop(PP_Instance instance) override; |
178 virtual PP_Resource CreatePlatformVerificationPrivate( | 178 virtual PP_Resource CreatePlatformVerificationPrivate( |
179 PP_Instance instance) OVERRIDE; | 179 PP_Instance instance) override; |
180 virtual PP_Resource CreateScrollbar(PP_Instance instance, | 180 virtual PP_Resource CreateScrollbar(PP_Instance instance, |
181 PP_Bool vertical) OVERRIDE; | 181 PP_Bool vertical) override; |
182 virtual PP_Resource CreateTalk(PP_Instance instance) OVERRIDE; | 182 virtual PP_Resource CreateTalk(PP_Instance instance) override; |
183 virtual PP_Resource CreateVideoCapture(PP_Instance instance) OVERRIDE; | 183 virtual PP_Resource CreateVideoCapture(PP_Instance instance) override; |
184 virtual PP_Resource CreateVideoDecoderDev( | 184 virtual PP_Resource CreateVideoDecoderDev( |
185 PP_Instance instance, | 185 PP_Instance instance, |
186 PP_Resource context3d_id, | 186 PP_Resource context3d_id, |
187 PP_VideoDecoder_Profile profile) OVERRIDE; | 187 PP_VideoDecoder_Profile profile) override; |
188 #endif // !defined(OS_NACL) | 188 #endif // !defined(OS_NACL) |
189 | 189 |
190 virtual bool Send(IPC::Message* msg) OVERRIDE; | 190 virtual bool Send(IPC::Message* msg) override; |
191 virtual bool OnMessageReceived(const IPC::Message& msg) OVERRIDE; | 191 virtual bool OnMessageReceived(const IPC::Message& msg) override; |
192 | 192 |
193 private: | 193 private: |
194 Connection GetConnection(); | 194 Connection GetConnection(); |
195 DISALLOW_COPY_AND_ASSIGN(ResourceCreationProxy); | 195 DISALLOW_COPY_AND_ASSIGN(ResourceCreationProxy); |
196 }; | 196 }; |
197 | 197 |
198 } // namespace proxy | 198 } // namespace proxy |
199 } // namespace ppapi | 199 } // namespace ppapi |
200 | 200 |
201 #endif // PPAPI_PROXY_RESOURCE_CREATION_PROXY_H_ | 201 #endif // PPAPI_PROXY_RESOURCE_CREATION_PROXY_H_ |
OLD | NEW |