| 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 | 5 |
| 6 /* From dev/ppb_testing_dev.idl modified Wed Dec 14 12:58:12 2011. */ | 6 /* From dev/ppb_testing_dev.idl modified Fri Dec 16 16:08:07 2011. */ |
| 7 | 7 |
| 8 #ifndef PPAPI_C_DEV_PPB_TESTING_DEV_H_ | 8 #ifndef PPAPI_C_DEV_PPB_TESTING_DEV_H_ |
| 9 #define PPAPI_C_DEV_PPB_TESTING_DEV_H_ | 9 #define PPAPI_C_DEV_PPB_TESTING_DEV_H_ |
| 10 | 10 |
| 11 #include "ppapi/c/dev/ppb_url_util_dev.h" | 11 #include "ppapi/c/dev/ppb_url_util_dev.h" |
| 12 #include "ppapi/c/pp_bool.h" | 12 #include "ppapi/c/pp_bool.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_resource.h" | 16 #include "ppapi/c/pp_resource.h" |
| 17 #include "ppapi/c/pp_stdint.h" | 17 #include "ppapi/c/pp_stdint.h" |
| 18 #include "ppapi/c/pp_var.h" | 18 #include "ppapi/c/pp_var.h" |
| 19 | 19 |
| 20 #define PPB_TESTING_DEV_INTERFACE_0_7 "PPB_Testing(Dev);0.7" | 20 #define PPB_TESTING_DEV_INTERFACE_0_7 "PPB_Testing(Dev);0.7" |
| 21 #define PPB_TESTING_DEV_INTERFACE_0_8 "PPB_Testing(Dev);0.8" | 21 #define PPB_TESTING_DEV_INTERFACE_0_8 "PPB_Testing(Dev);0.8" |
| 22 #define PPB_TESTING_DEV_INTERFACE_0_9 "PPB_Testing(Dev);0.9" | 22 #define PPB_TESTING_DEV_INTERFACE_0_9 "PPB_Testing(Dev);0.9" |
| 23 #define PPB_TESTING_DEV_INTERFACE PPB_TESTING_DEV_INTERFACE_0_9 | 23 #define PPB_TESTING_DEV_INTERFACE_0_91 "PPB_Testing(Dev);0.91" |
| 24 #define PPB_TESTING_DEV_INTERFACE PPB_TESTING_DEV_INTERFACE_0_91 |
| 24 | 25 |
| 25 /** | 26 /** |
| 26 * @file | 27 * @file |
| 27 * This file contains interface functions used for unit testing. Do not use in | 28 * This file contains interface functions used for unit testing. Do not use in |
| 28 * production code. They are not guaranteed to be available in normal plugin | 29 * production code. They are not guaranteed to be available in normal plugin |
| 29 * environments so you should not depend on them. | 30 * environments so you should not depend on them. |
| 30 */ | 31 */ |
| 31 | 32 |
| 32 | 33 |
| 33 /** | 34 /** |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 117 void (*SimulateInputEvent)(PP_Instance instance, PP_Resource input_event); | 118 void (*SimulateInputEvent)(PP_Instance instance, PP_Resource input_event); |
| 118 /** | 119 /** |
| 119 * Returns the URL for the document. This is a safe way to retrieve | 120 * Returns the URL for the document. This is a safe way to retrieve |
| 120 * window.location.href. | 121 * window.location.href. |
| 121 * If the canonicalized URL is valid, the method will parse the URL | 122 * If the canonicalized URL is valid, the method will parse the URL |
| 122 * and fill in the components structure. This pointer may be NULL | 123 * and fill in the components structure. This pointer may be NULL |
| 123 * to specify that no component information is necessary. | 124 * to specify that no component information is necessary. |
| 124 */ | 125 */ |
| 125 struct PP_Var (*GetDocumentURL)(PP_Instance instance, | 126 struct PP_Var (*GetDocumentURL)(PP_Instance instance, |
| 126 struct PP_URLComponents_Dev* components); | 127 struct PP_URLComponents_Dev* components); |
| 128 /** |
| 129 * Fetches up to |array_size| active PP_Vars in the tracker. Returns the |
| 130 * number of vars in the tracker. The active vars are written to |live_vars| |
| 131 * contiguously starting at index 0. The vars are not in any particular order. |
| 132 * If the number of live vars is greater than |array_size|, then an arbitrary |
| 133 * subset of |array_size| vars is written to |live_vars|. The reference count |
| 134 * of the returned PP_Vars will *not* be affected by this call. |
| 135 */ |
| 136 uint32_t (*GetLiveVars)(struct PP_Var live_vars[], uint32_t array_size); |
| 127 }; | 137 }; |
| 128 | 138 |
| 129 struct PPB_Testing_Dev_0_7 { | 139 struct PPB_Testing_Dev_0_7 { |
| 130 PP_Bool (*ReadImageData)(PP_Resource device_context_2d, | 140 PP_Bool (*ReadImageData)(PP_Resource device_context_2d, |
| 131 PP_Resource image, | 141 PP_Resource image, |
| 132 const struct PP_Point* top_left); | 142 const struct PP_Point* top_left); |
| 133 void (*RunMessageLoop)(PP_Instance instance); | 143 void (*RunMessageLoop)(PP_Instance instance); |
| 134 void (*QuitMessageLoop)(PP_Instance instance); | 144 void (*QuitMessageLoop)(PP_Instance instance); |
| 135 uint32_t (*GetLiveObjectsForInstance)(PP_Instance instance); | 145 uint32_t (*GetLiveObjectsForInstance)(PP_Instance instance); |
| 136 PP_Bool (*IsOutOfProcess)(); | 146 PP_Bool (*IsOutOfProcess)(); |
| 137 }; | 147 }; |
| 138 | 148 |
| 139 struct PPB_Testing_Dev_0_8 { | 149 struct PPB_Testing_Dev_0_8 { |
| 140 PP_Bool (*ReadImageData)(PP_Resource device_context_2d, | 150 PP_Bool (*ReadImageData)(PP_Resource device_context_2d, |
| 141 PP_Resource image, | 151 PP_Resource image, |
| 142 const struct PP_Point* top_left); | 152 const struct PP_Point* top_left); |
| 143 void (*RunMessageLoop)(PP_Instance instance); | 153 void (*RunMessageLoop)(PP_Instance instance); |
| 144 void (*QuitMessageLoop)(PP_Instance instance); | 154 void (*QuitMessageLoop)(PP_Instance instance); |
| 145 uint32_t (*GetLiveObjectsForInstance)(PP_Instance instance); | 155 uint32_t (*GetLiveObjectsForInstance)(PP_Instance instance); |
| 146 PP_Bool (*IsOutOfProcess)(); | 156 PP_Bool (*IsOutOfProcess)(); |
| 147 void (*SimulateInputEvent)(PP_Instance instance, PP_Resource input_event); | 157 void (*SimulateInputEvent)(PP_Instance instance, PP_Resource input_event); |
| 148 }; | 158 }; |
| 159 |
| 160 struct PPB_Testing_Dev_0_9 { |
| 161 PP_Bool (*ReadImageData)(PP_Resource device_context_2d, |
| 162 PP_Resource image, |
| 163 const struct PP_Point* top_left); |
| 164 void (*RunMessageLoop)(PP_Instance instance); |
| 165 void (*QuitMessageLoop)(PP_Instance instance); |
| 166 uint32_t (*GetLiveObjectsForInstance)(PP_Instance instance); |
| 167 PP_Bool (*IsOutOfProcess)(); |
| 168 void (*SimulateInputEvent)(PP_Instance instance, PP_Resource input_event); |
| 169 struct PP_Var (*GetDocumentURL)(PP_Instance instance, |
| 170 struct PP_URLComponents_Dev* components); |
| 171 }; |
| 149 /** | 172 /** |
| 150 * @} | 173 * @} |
| 151 */ | 174 */ |
| 152 | 175 |
| 153 #endif /* PPAPI_C_DEV_PPB_TESTING_DEV_H_ */ | 176 #endif /* PPAPI_C_DEV_PPB_TESTING_DEV_H_ */ |
| 154 | 177 |
| OLD | NEW |