OLD | NEW |
1 /* Copyright 2013 The Chromium Authors. All rights reserved. | 1 /* Copyright 2013 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 dev/ppb_var_resource_dev.idl modified Fri Oct 11 10:31:47 2013. */ | 6 /* From ppb_var_resource.idl modified Tue Feb 4 19:14:01 2014. */ |
7 | 7 |
8 #ifndef PPAPI_C_DEV_PPB_VAR_RESOURCE_DEV_H_ | 8 #ifndef PPAPI_C_PPB_VAR_RESOURCE_H_ |
9 #define PPAPI_C_DEV_PPB_VAR_RESOURCE_DEV_H_ | 9 #define PPAPI_C_PPB_VAR_RESOURCE_H_ |
10 | 10 |
11 #include "ppapi/c/pp_bool.h" | 11 #include "ppapi/c/pp_bool.h" |
12 #include "ppapi/c/pp_macros.h" | 12 #include "ppapi/c/pp_macros.h" |
13 #include "ppapi/c/pp_resource.h" | 13 #include "ppapi/c/pp_resource.h" |
14 #include "ppapi/c/pp_stdint.h" | 14 #include "ppapi/c/pp_stdint.h" |
15 #include "ppapi/c/pp_var.h" | 15 #include "ppapi/c/pp_var.h" |
16 | 16 |
17 #define PPB_VAR_RESOURCE_DEV_INTERFACE_0_1 "PPB_VarResource(Dev);0.1" | 17 #define PPB_VAR_RESOURCE_INTERFACE_1_0 "PPB_VarResource;1.0" |
18 #define PPB_VAR_RESOURCE_DEV_INTERFACE PPB_VAR_RESOURCE_DEV_INTERFACE_0_1 | 18 #define PPB_VAR_RESOURCE_INTERFACE PPB_VAR_RESOURCE_INTERFACE_1_0 |
19 | 19 |
20 /** | 20 /** |
21 * @file | 21 * @file |
22 * This file defines the <code>PPB_VarResource</code> struct providing | 22 * This file defines the <code>PPB_VarResource</code> struct providing |
23 * a way to interact with resource vars. | 23 * a way to interact with resource vars. |
24 */ | 24 */ |
25 | 25 |
26 | 26 |
27 /** | 27 /** |
28 * @addtogroup Interfaces | 28 * @addtogroup Interfaces |
29 * @{ | 29 * @{ |
30 */ | 30 */ |
31 struct PPB_VarResource_Dev_0_1 { | 31 struct PPB_VarResource_1_0 { |
32 /** | 32 /** |
33 * Converts a resource-type var to a <code>PP_Resource</code>. | 33 * Converts a resource-type var to a <code>PP_Resource</code>. |
34 * | 34 * |
35 * @param[in] var A <code>PP_Var</code> struct containing a resource-type var. | 35 * @param[in] var A <code>PP_Var</code> struct containing a resource-type var. |
36 * | 36 * |
37 * @return A <code>PP_Resource</code> retrieved from the var, or 0 if the var | 37 * @return A <code>PP_Resource</code> retrieved from the var, or 0 if the var |
38 * is not a resource. The reference count of the resource is incremented on | 38 * is not a resource. The reference count of the resource is incremented on |
39 * behalf of the caller. | 39 * behalf of the caller. |
40 */ | 40 */ |
41 PP_Resource (*VarToResource)(struct PP_Var var); | 41 PP_Resource (*VarToResource)(struct PP_Var var); |
42 /** | 42 /** |
43 * Creates a new <code>PP_Var</code> from a given resource. | 43 * Creates a new <code>PP_Var</code> from a given resource. |
44 * | 44 * |
45 * @param[in] resource A <code>PP_Resource</code> to be wrapped in a var. | 45 * @param[in] resource A <code>PP_Resource</code> to be wrapped in a var. |
46 * | 46 * |
47 * @return A <code>PP_Var</code> created for this resource, with type | 47 * @return A <code>PP_Var</code> created for this resource, with type |
48 * <code>PP_VARTYPE_RESOURCE</code>. The reference count of the var is set to | 48 * <code>PP_VARTYPE_RESOURCE</code>. The reference count of the var is set to |
49 * 1 on behalf of the caller. | 49 * 1 on behalf of the caller. |
50 */ | 50 */ |
51 struct PP_Var (*VarFromResource)(PP_Resource resource); | 51 struct PP_Var (*VarFromResource)(PP_Resource resource); |
52 }; | 52 }; |
53 | 53 |
54 typedef struct PPB_VarResource_Dev_0_1 PPB_VarResource_Dev; | 54 typedef struct PPB_VarResource_1_0 PPB_VarResource; |
55 /** | 55 /** |
56 * @} | 56 * @} |
57 */ | 57 */ |
58 | 58 |
59 #endif /* PPAPI_C_DEV_PPB_VAR_RESOURCE_DEV_H_ */ | 59 #endif /* PPAPI_C_PPB_VAR_RESOURCE_H_ */ |
60 | 60 |
OLD | NEW |