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 | 5 |
6 /* From ppb_graphics_2d.idl modified Thu Jan 12 16:11:14 2012. */ | 6 /* From ppb_graphics_2d.idl modified Mon Jan 23 13:21:04 2012. */ |
7 | 7 |
8 #ifndef PPAPI_C_PPB_GRAPHICS_2D_H_ | 8 #ifndef PPAPI_C_PPB_GRAPHICS_2D_H_ |
9 #define PPAPI_C_PPB_GRAPHICS_2D_H_ | 9 #define PPAPI_C_PPB_GRAPHICS_2D_H_ |
10 | 10 |
11 #include "ppapi/c/pp_bool.h" | 11 #include "ppapi/c/pp_bool.h" |
12 #include "ppapi/c/pp_completion_callback.h" | 12 #include "ppapi/c/pp_completion_callback.h" |
13 #include "ppapi/c/pp_instance.h" | 13 #include "ppapi/c/pp_instance.h" |
14 #include "ppapi/c/pp_macros.h" | 14 #include "ppapi/c/pp_macros.h" |
15 #include "ppapi/c/pp_point.h" | 15 #include "ppapi/c/pp_point.h" |
16 #include "ppapi/c/pp_rect.h" | 16 #include "ppapi/c/pp_rect.h" |
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
238 * the image has been painted on the screen. | 238 * the image has been painted on the screen. |
239 * | 239 * |
240 * @return Returns <code>PP_OK</code> on success or | 240 * @return Returns <code>PP_OK</code> on success or |
241 * <code>PP_ERROR_BADRESOURCE</code> if the graphics context is invalid, | 241 * <code>PP_ERROR_BADRESOURCE</code> if the graphics context is invalid, |
242 * <code>PP_ERROR_BADARGUMENT</code> if the callback is null and flush is | 242 * <code>PP_ERROR_BADARGUMENT</code> if the callback is null and flush is |
243 * being called from the main thread of the module, or | 243 * being called from the main thread of the module, or |
244 * <code>PP_ERROR_INPROGRESS</code> if a flush is already pending that has | 244 * <code>PP_ERROR_INPROGRESS</code> if a flush is already pending that has |
245 * not issued its callback yet. In the failure case, nothing will be updated | 245 * not issued its callback yet. In the failure case, nothing will be updated |
246 * and no callback will be scheduled. | 246 * and no callback will be scheduled. |
247 */ | 247 */ |
248 /* | 248 /* TODO(darin): We should ensure that the completion callback always runs, so |
249 * TODO(darin): We should ensure that the completion callback always runs, so | |
250 * that it is easier for consumers to manage memory referenced by a callback. | 249 * that it is easier for consumers to manage memory referenced by a callback. |
251 */ | 250 */ |
252 /* | 251 /* TODO(): Add back in the synchronous mode description once we have support |
253 * TODO(): Add back in the synchronous mode description once we have support | |
254 * for it. | 252 * for it. |
255 */ | 253 */ |
256 int32_t (*Flush)(PP_Resource graphics_2d, | 254 int32_t (*Flush)(PP_Resource graphics_2d, |
257 struct PP_CompletionCallback callback); | 255 struct PP_CompletionCallback callback); |
258 }; | 256 }; |
259 | 257 |
260 typedef struct PPB_Graphics2D_1_0 PPB_Graphics2D; | 258 typedef struct PPB_Graphics2D_1_0 PPB_Graphics2D; |
261 /** | 259 /** |
262 * @} | 260 * @} |
263 */ | 261 */ |
264 | 262 |
265 #endif /* PPAPI_C_PPB_GRAPHICS_2D_H_ */ | 263 #endif /* PPAPI_C_PPB_GRAPHICS_2D_H_ */ |
266 | 264 |
OLD | NEW |