Commit 8c2a548b authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

jscript: Rename DispatchEx to jsdisp_t to match jscript naming convention.

parent 4a352bd7
......@@ -181,9 +181,9 @@ static HRESULT ActiveXObject_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flag
return S_OK;
}
HRESULT create_activex_constr(script_ctx_t *ctx, DispatchEx **ret)
HRESULT create_activex_constr(script_ctx_t *ctx, jsdisp_t **ret)
{
DispatchEx *prototype;
jsdisp_t *prototype;
HRESULT hres;
static const WCHAR ActiveXObjectW[] = {'A','c','t','i','v','e','X','O','b','j','e','c','t',0};
......
......@@ -25,7 +25,7 @@
WINE_DEFAULT_DEBUG_CHANNEL(jscript);
typedef struct {
DispatchEx dispex;
jsdisp_t dispex;
DWORD length;
} ArrayInstance;
......@@ -56,7 +56,7 @@ static inline ArrayInstance *array_this(vdisp_t *jsthis)
return is_vclass(jsthis, JSCLASS_ARRAY) ? array_from_vdisp(jsthis) : NULL;
}
static HRESULT get_length(script_ctx_t *ctx, vdisp_t *vdisp, jsexcept_t *ei, DispatchEx **jsthis, DWORD *ret)
static HRESULT get_length(script_ctx_t *ctx, vdisp_t *vdisp, jsexcept_t *ei, jsdisp_t **jsthis, DWORD *ret)
{
ArrayInstance *array;
VARIANT var;
......@@ -85,7 +85,7 @@ static HRESULT get_length(script_ctx_t *ctx, vdisp_t *vdisp, jsexcept_t *ei, Dis
return S_OK;
}
static HRESULT set_length(DispatchEx *obj, jsexcept_t *ei, DWORD length)
static HRESULT set_length(jsdisp_t *obj, jsexcept_t *ei, DWORD length)
{
VARIANT var;
......@@ -158,7 +158,7 @@ static HRESULT Array_length(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DISP
return S_OK;
}
static HRESULT concat_array(DispatchEx *array, ArrayInstance *obj, DWORD *len,
static HRESULT concat_array(jsdisp_t *array, ArrayInstance *obj, DWORD *len,
jsexcept_t *ei, IServiceProvider *caller)
{
VARIANT var;
......@@ -182,9 +182,9 @@ static HRESULT concat_array(DispatchEx *array, ArrayInstance *obj, DWORD *len,
return S_OK;
}
static HRESULT concat_obj(DispatchEx *array, IDispatch *obj, DWORD *len, jsexcept_t *ei, IServiceProvider *caller)
static HRESULT concat_obj(jsdisp_t *array, IDispatch *obj, DWORD *len, jsexcept_t *ei, IServiceProvider *caller)
{
DispatchEx *jsobj;
jsdisp_t *jsobj;
VARIANT var;
HRESULT hres;
......@@ -206,7 +206,7 @@ static HRESULT concat_obj(DispatchEx *array, IDispatch *obj, DWORD *len, jsexcep
static HRESULT Array_concat(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller)
{
DispatchEx *ret;
jsdisp_t *ret;
DWORD len = 0;
HRESULT hres;
......@@ -244,7 +244,7 @@ static HRESULT Array_concat(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DISP
return S_OK;
}
static HRESULT array_join(script_ctx_t *ctx, DispatchEx *array, DWORD length, const WCHAR *sep, VARIANT *retv,
static HRESULT array_join(script_ctx_t *ctx, jsdisp_t *array, DWORD length, const WCHAR *sep, VARIANT *retv,
jsexcept_t *ei, IServiceProvider *caller)
{
BSTR *str_tab, ret = NULL;
......@@ -348,7 +348,7 @@ static HRESULT array_join(script_ctx_t *ctx, DispatchEx *array, DWORD length, co
static HRESULT Array_join(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller)
{
DispatchEx *jsthis;
jsdisp_t *jsthis;
DWORD length;
HRESULT hres;
......@@ -378,7 +378,7 @@ static HRESULT Array_join(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPAR
static HRESULT Array_pop(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller)
{
DispatchEx *jsthis;
jsdisp_t *jsthis;
VARIANT val;
DWORD length;
HRESULT hres;
......@@ -429,7 +429,7 @@ static HRESULT Array_pop(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPARA
static HRESULT Array_push(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp)
{
DispatchEx *jsthis;
jsdisp_t *jsthis;
DWORD length = 0;
int i, n;
HRESULT hres;
......@@ -461,7 +461,7 @@ static HRESULT Array_push(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPAR
static HRESULT Array_reverse(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp)
{
DispatchEx *jsthis;
jsdisp_t *jsthis;
DWORD length, k, l;
VARIANT v1, v2;
HRESULT hres1, hres2;
......@@ -520,7 +520,7 @@ static HRESULT Array_reverse(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISP
static HRESULT Array_shift(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller)
{
DispatchEx *jsthis;
jsdisp_t *jsthis;
DWORD length = 0, i;
VARIANT v, ret;
HRESULT hres;
......@@ -574,7 +574,7 @@ static HRESULT Array_shift(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPA
static HRESULT Array_slice(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp)
{
DispatchEx *arr, *jsthis;
jsdisp_t *arr, *jsthis;
VARIANT v;
DOUBLE range;
DWORD length, start, end, idx;
......@@ -650,7 +650,7 @@ static HRESULT Array_slice(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPA
return S_OK;
}
static HRESULT sort_cmp(script_ctx_t *ctx, DispatchEx *cmp_func, VARIANT *v1, VARIANT *v2, jsexcept_t *ei,
static HRESULT sort_cmp(script_ctx_t *ctx, jsdisp_t *cmp_func, VARIANT *v1, VARIANT *v2, jsexcept_t *ei,
IServiceProvider *caller, INT *cmp)
{
HRESULT hres;
......@@ -711,7 +711,7 @@ static HRESULT sort_cmp(script_ctx_t *ctx, DispatchEx *cmp_func, VARIANT *v1, VA
static HRESULT Array_sort(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller)
{
DispatchEx *jsthis, *cmp_func = NULL;
jsdisp_t *jsthis, *cmp_func = NULL;
VARIANT *vtab, **sorttab = NULL;
DWORD length;
DWORD i;
......@@ -869,7 +869,7 @@ static HRESULT Array_splice(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPP
VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller)
{
DWORD length, start=0, delete_cnt=0, argc, i, add_args = 0;
DispatchEx *ret_array = NULL, *jsthis;
jsdisp_t *ret_array = NULL, *jsthis;
VARIANT v;
HRESULT hres = S_OK;
......@@ -1000,7 +1000,7 @@ static HRESULT Array_toLocaleString(script_ctx_t *ctx, vdisp_t *vthis, WORD flag
static HRESULT Array_unshift(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller)
{
DispatchEx *jsthis;
jsdisp_t *jsthis;
WCHAR buf[14], *buf_end, *str;
DWORD argc, i, length;
VARIANT var;
......@@ -1081,12 +1081,12 @@ static HRESULT Array_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DISPP
return S_OK;
}
static void Array_destructor(DispatchEx *dispex)
static void Array_destructor(jsdisp_t *dispex)
{
heap_free(dispex);
}
static void Array_on_put(DispatchEx *dispex, const WCHAR *name)
static void Array_on_put(jsdisp_t *dispex, const WCHAR *name)
{
ArrayInstance *array = (ArrayInstance*)dispex;
const WCHAR *ptr = name;
......@@ -1135,7 +1135,7 @@ static const builtin_info_t Array_info = {
static HRESULT ArrayConstr_value(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller)
{
DispatchEx *obj;
jsdisp_t *obj;
VARIANT *arg_var;
DWORD i;
HRESULT hres;
......@@ -1184,7 +1184,7 @@ static HRESULT ArrayConstr_value(script_ctx_t *ctx, vdisp_t *vthis, WORD flags,
return S_OK;
}
static HRESULT alloc_array(script_ctx_t *ctx, DispatchEx *object_prototype, ArrayInstance **ret)
static HRESULT alloc_array(script_ctx_t *ctx, jsdisp_t *object_prototype, ArrayInstance **ret)
{
ArrayInstance *array;
HRESULT hres;
......@@ -1207,7 +1207,7 @@ static HRESULT alloc_array(script_ctx_t *ctx, DispatchEx *object_prototype, Arra
return S_OK;
}
HRESULT create_array_constr(script_ctx_t *ctx, DispatchEx *object_prototype, DispatchEx **ret)
HRESULT create_array_constr(script_ctx_t *ctx, jsdisp_t *object_prototype, jsdisp_t **ret)
{
ArrayInstance *array;
HRESULT hres;
......@@ -1224,7 +1224,7 @@ HRESULT create_array_constr(script_ctx_t *ctx, DispatchEx *object_prototype, Dis
return hres;
}
HRESULT create_array(script_ctx_t *ctx, DWORD length, DispatchEx **ret)
HRESULT create_array(script_ctx_t *ctx, DWORD length, jsdisp_t **ret)
{
ArrayInstance *array;
HRESULT hres;
......
......@@ -24,7 +24,7 @@
WINE_DEFAULT_DEBUG_CHANNEL(jscript);
typedef struct {
DispatchEx dispex;
jsdisp_t dispex;
VARIANT_BOOL val;
} BoolInstance;
......@@ -131,7 +131,7 @@ static HRESULT BoolConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags,
switch(flags) {
case DISPATCH_CONSTRUCT: {
DispatchEx *bool;
jsdisp_t *bool;
hres = create_bool(ctx, value, &bool);
if(FAILED(hres))
......@@ -157,7 +157,7 @@ static HRESULT BoolConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags,
return S_OK;
}
static HRESULT alloc_bool(script_ctx_t *ctx, DispatchEx *object_prototype, BoolInstance **ret)
static HRESULT alloc_bool(script_ctx_t *ctx, jsdisp_t *object_prototype, BoolInstance **ret)
{
BoolInstance *bool;
HRESULT hres;
......@@ -180,7 +180,7 @@ static HRESULT alloc_bool(script_ctx_t *ctx, DispatchEx *object_prototype, BoolI
return S_OK;
}
HRESULT create_bool_constr(script_ctx_t *ctx, DispatchEx *object_prototype, DispatchEx **ret)
HRESULT create_bool_constr(script_ctx_t *ctx, jsdisp_t *object_prototype, jsdisp_t **ret)
{
BoolInstance *bool;
HRESULT hres;
......@@ -198,7 +198,7 @@ HRESULT create_bool_constr(script_ctx_t *ctx, DispatchEx *object_prototype, Disp
return hres;
}
HRESULT create_bool(script_ctx_t *ctx, VARIANT_BOOL b, DispatchEx **ret)
HRESULT create_bool(script_ctx_t *ctx, VARIANT_BOOL b, jsdisp_t **ret)
{
BoolInstance *bool;
HRESULT hres;
......
......@@ -33,7 +33,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(jscript);
#define TIME_EPOCH ((ULONGLONG)(369 * 365 + 89) * 86400 * 1000)
typedef struct {
DispatchEx dispex;
jsdisp_t dispex;
/* ECMA-262 3rd Edition 15.9.1.1 */
DOUBLE time;
......@@ -2094,7 +2094,7 @@ static const builtin_info_t Date_info = {
NULL
};
static HRESULT create_date(script_ctx_t *ctx, DispatchEx *object_prototype, DOUBLE time, DispatchEx **ret)
static HRESULT create_date(script_ctx_t *ctx, jsdisp_t *object_prototype, DOUBLE time, jsdisp_t **ret)
{
DateInstance *date;
HRESULT hres;
......@@ -2511,7 +2511,7 @@ static HRESULT DateConstr_UTC(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DI
static HRESULT DateConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp)
{
DispatchEx *date;
jsdisp_t *date;
HRESULT hres;
TRACE("\n");
......@@ -2613,9 +2613,9 @@ static const builtin_info_t DateConstr_info = {
NULL
};
HRESULT create_date_constr(script_ctx_t *ctx, DispatchEx *object_prototype, DispatchEx **ret)
HRESULT create_date_constr(script_ctx_t *ctx, jsdisp_t *object_prototype, jsdisp_t **ret)
{
DispatchEx *date;
jsdisp_t *date;
HRESULT hres;
static const WCHAR DateW[] = {'D','a','t','e',0};
......
......@@ -133,7 +133,7 @@ static void exprval_set_idref(exprval_t *val, IDispatch *disp, DISPID id)
IDispatch_AddRef(disp);
}
HRESULT scope_push(scope_chain_t *scope, DispatchEx *obj, scope_chain_t **ret)
HRESULT scope_push(scope_chain_t *scope, jsdisp_t *obj, scope_chain_t **ret)
{
scope_chain_t *new_scope;
......@@ -178,7 +178,7 @@ void scope_release(scope_chain_t *scope)
heap_free(scope);
}
HRESULT create_exec_ctx(script_ctx_t *script_ctx, IDispatch *this_obj, DispatchEx *var_disp,
HRESULT create_exec_ctx(script_ctx_t *script_ctx, IDispatch *this_obj, jsdisp_t *var_disp,
scope_chain_t *scope, exec_ctx_t **ret)
{
exec_ctx_t *ctx;
......@@ -375,7 +375,7 @@ static HRESULT literal_to_var(script_ctx_t *ctx, literal_t *literal, VARIANT *v)
V_BOOL(v) = literal->u.bval;
break;
case LT_REGEXP: {
DispatchEx *regexp;
jsdisp_t *regexp;
HRESULT hres;
hres = create_regexp(ctx, literal->u.regexp.str, literal->u.regexp.str_len,
......@@ -425,7 +425,7 @@ HRESULT exec_source(exec_ctx_t *ctx, parser_ctx_t *parser, source_elements_t *so
HRESULT hres = S_OK;
for(func = source->functions; func; func = func->next) {
DispatchEx *func_obj;
jsdisp_t *func_obj;
VARIANT var;
hres = create_source_function(parser, func->expr->parameter_list, func->expr->source_elements,
......@@ -1021,7 +1021,7 @@ HRESULT with_statement_eval(exec_ctx_t *ctx, statement_t *_stat, return_type_t *
with_statement_t *stat = (with_statement_t*)_stat;
exprval_t exprval;
IDispatch *disp;
DispatchEx *obj;
jsdisp_t *obj;
VARIANT val;
HRESULT hres;
......@@ -1171,7 +1171,7 @@ HRESULT throw_statement_eval(exec_ctx_t *ctx, statement_t *_stat, return_type_t
/* ECMA-262 3rd Edition 12.14 */
static HRESULT catch_eval(exec_ctx_t *ctx, catch_block_t *block, return_type_t *rt, VARIANT *ret)
{
DispatchEx *var_disp;
jsdisp_t *var_disp;
VARIANT ex, val;
HRESULT hres;
......@@ -1346,7 +1346,7 @@ HRESULT function_expression_eval(exec_ctx_t *ctx, expression_t *_expr, DWORD fla
if(FAILED(hres))
return hres;
}else {
DispatchEx *dispex;
jsdisp_t *dispex;
hres = create_source_function(ctx->parser, expr->parameter_list, expr->source_elements, ctx->scope_chain,
expr->src_str, expr->src_len, &dispex);
......@@ -1692,7 +1692,7 @@ HRESULT array_literal_expression_eval(exec_ctx_t *ctx, expression_t *_expr, DWOR
array_literal_expression_t *expr = (array_literal_expression_t*)_expr;
DWORD length = 0, i = 0;
array_element_t *elem;
DispatchEx *array;
jsdisp_t *array;
exprval_t exprval;
VARIANT val;
HRESULT hres;
......@@ -1743,7 +1743,7 @@ HRESULT property_value_expression_eval(exec_ctx_t *ctx, expression_t *_expr, DWO
{
property_value_expression_t *expr = (property_value_expression_t*)_expr;
VARIANT val, tmp;
DispatchEx *obj;
jsdisp_t *obj;
prop_val_t *iter;
exprval_t exprval;
BSTR name;
......@@ -1991,7 +1991,7 @@ HRESULT binary_and_expression_eval(exec_ctx_t *ctx, expression_t *_expr, DWORD f
/* ECMA-262 3rd Edition 11.8.6 */
static HRESULT instanceof_eval(exec_ctx_t *ctx, VARIANT *inst, VARIANT *objv, jsexcept_t *ei, VARIANT *retv)
{
DispatchEx *obj, *iter, *tmp = NULL;
jsdisp_t *obj, *iter, *tmp = NULL;
VARIANT_BOOL ret = VARIANT_FALSE;
BOOL b;
VARIANT var;
......@@ -2397,7 +2397,7 @@ static HRESULT typeof_exprval(exec_ctx_t *ctx, exprval_t *exprval, jsexcept_t *e
*ret = stringW;
break;
case VT_DISPATCH: {
DispatchEx *dispex;
jsdisp_t *dispex;
if(V_DISPATCH(&val) && (dispex = iface_to_jsdisp((IUnknown*)V_DISPATCH(&val)))) {
*ret = is_class(dispex, JSCLASS_FUNCTION) ? functionW : objectW;
......
......@@ -83,11 +83,11 @@ static inline void *parser_alloc_tmp(parser_ctx_t *ctx, DWORD size)
typedef struct _scope_chain_t {
LONG ref;
DispatchEx *obj;
jsdisp_t *obj;
struct _scope_chain_t *next;
} scope_chain_t;
HRESULT scope_push(scope_chain_t*,DispatchEx*,scope_chain_t**);
HRESULT scope_push(scope_chain_t*,jsdisp_t*,scope_chain_t**);
void scope_release(scope_chain_t*);
static inline void scope_addref(scope_chain_t *scope)
......@@ -100,7 +100,7 @@ struct _exec_ctx_t {
parser_ctx_t *parser;
scope_chain_t *scope_chain;
DispatchEx *var_disp;
jsdisp_t *var_disp;
IDispatch *this_obj;
};
......@@ -116,7 +116,7 @@ typedef enum {
} exec_type_t;
void exec_release(exec_ctx_t*);
HRESULT create_exec_ctx(script_ctx_t*,IDispatch*,DispatchEx*,scope_chain_t*,exec_ctx_t**);
HRESULT create_exec_ctx(script_ctx_t*,IDispatch*,jsdisp_t*,scope_chain_t*,exec_ctx_t**);
HRESULT exec_source(exec_ctx_t*,parser_ctx_t*,source_elements_t*,exec_type_t,jsexcept_t*,VARIANT*);
typedef struct _statement_t statement_t;
......@@ -124,7 +124,7 @@ typedef struct _expression_t expression_t;
typedef struct _parameter_t parameter_t;
HRESULT create_source_function(parser_ctx_t*,parameter_t*,source_elements_t*,scope_chain_t*,
const WCHAR*,DWORD,DispatchEx**);
const WCHAR*,DWORD,jsdisp_t**);
typedef enum {
LT_INT,
......
......@@ -36,7 +36,7 @@ static const WCHAR toStringW[] = {'t','o','S','t','r','i','n','g',0};
static HRESULT Error_toString(script_ctx_t *ctx, vdisp_t *vthis, WORD flags,
DISPPARAMS *dp, VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller)
{
DispatchEx *jsthis;
jsdisp_t *jsthis;
BSTR name = NULL, msg = NULL, ret = NULL;
VARIANT v;
HRESULT hres;
......@@ -165,10 +165,10 @@ static const builtin_info_t ErrorInst_info = {
NULL
};
static HRESULT alloc_error(script_ctx_t *ctx, DispatchEx *prototype,
DispatchEx *constr, DispatchEx **ret)
static HRESULT alloc_error(script_ctx_t *ctx, jsdisp_t *prototype,
jsdisp_t *constr, jsdisp_t **ret)
{
DispatchEx *err;
jsdisp_t *err;
HRESULT hres;
err = heap_alloc_zero(sizeof(*err));
......@@ -189,10 +189,10 @@ static HRESULT alloc_error(script_ctx_t *ctx, DispatchEx *prototype,
return S_OK;
}
static HRESULT create_error(script_ctx_t *ctx, DispatchEx *constr,
UINT number, const WCHAR *msg, DispatchEx **ret)
static HRESULT create_error(script_ctx_t *ctx, jsdisp_t *constr,
UINT number, const WCHAR *msg, jsdisp_t **ret)
{
DispatchEx *err;
jsdisp_t *err;
VARIANT v;
HRESULT hres;
......@@ -229,8 +229,8 @@ static HRESULT create_error(script_ctx_t *ctx, DispatchEx *constr,
}
static HRESULT error_constr(script_ctx_t *ctx, WORD flags, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, DispatchEx *constr) {
DispatchEx *err;
VARIANT *retv, jsexcept_t *ei, jsdisp_t *constr) {
jsdisp_t *err;
UINT num = 0;
BSTR msg = NULL;
HRESULT hres;
......@@ -336,7 +336,7 @@ static HRESULT URIErrorConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD fla
return error_constr(ctx, flags, dp, retv, ei, ctx->uri_error_constr);
}
HRESULT init_error_constr(script_ctx_t *ctx, DispatchEx *object_prototype)
HRESULT init_error_constr(script_ctx_t *ctx, jsdisp_t *object_prototype)
{
static const WCHAR ErrorW[] = {'E','r','r','o','r',0};
static const WCHAR EvalErrorW[] = {'E','v','a','l','E','r','r','o','r',0};
......@@ -348,7 +348,7 @@ HRESULT init_error_constr(script_ctx_t *ctx, DispatchEx *object_prototype)
static const WCHAR URIErrorW[] = {'U','R','I','E','r','r','o','r',0};
static const WCHAR *names[] = {ErrorW, EvalErrorW, RangeErrorW,
ReferenceErrorW, RegExpErrorW, SyntaxErrorW, TypeErrorW, URIErrorW};
DispatchEx **constr_addr[] = {&ctx->error_constr, &ctx->eval_error_constr,
jsdisp_t **constr_addr[] = {&ctx->error_constr, &ctx->eval_error_constr,
&ctx->range_error_constr, &ctx->reference_error_constr, &ctx->regexp_error_constr,
&ctx->syntax_error_constr, &ctx->type_error_constr,
&ctx->uri_error_constr};
......@@ -356,7 +356,7 @@ HRESULT init_error_constr(script_ctx_t *ctx, DispatchEx *object_prototype)
RangeErrorConstr_value, ReferenceErrorConstr_value, RegExpErrorConstr_value,
SyntaxErrorConstr_value, TypeErrorConstr_value, URIErrorConstr_value};
DispatchEx *err;
jsdisp_t *err;
INT i;
VARIANT v;
HRESULT hres;
......@@ -388,10 +388,10 @@ HRESULT init_error_constr(script_ctx_t *ctx, DispatchEx *object_prototype)
return S_OK;
}
static HRESULT throw_error(script_ctx_t *ctx, jsexcept_t *ei, UINT id, const WCHAR *str, DispatchEx *constr)
static HRESULT throw_error(script_ctx_t *ctx, jsexcept_t *ei, UINT id, const WCHAR *str, jsdisp_t *constr)
{
WCHAR buf[1024], *pos = NULL;
DispatchEx *err;
jsdisp_t *err;
HRESULT hres;
buf[0] = '\0';
......
......@@ -24,7 +24,7 @@
WINE_DEFAULT_DEBUG_CHANNEL(jscript);
typedef struct {
DispatchEx dispex;
jsdisp_t dispex;
builtin_invoke_t value_proc;
const WCHAR *name;
DWORD flags;
......@@ -35,7 +35,7 @@ typedef struct {
const WCHAR *src_str;
DWORD src_len;
DWORD length;
DispatchEx *arguments;
jsdisp_t *arguments;
} FunctionInstance;
static inline FunctionInstance *function_from_vdisp(vdisp_t *vdisp)
......@@ -74,7 +74,7 @@ static IDispatch *get_this(DISPPARAMS *dp)
return NULL;
}
static HRESULT init_parameters(DispatchEx *var_disp, FunctionInstance *function, DISPPARAMS *dp,
static HRESULT init_parameters(jsdisp_t *var_disp, FunctionInstance *function, DISPPARAMS *dp,
jsexcept_t *ei, IServiceProvider *caller)
{
parameter_t *param;
......@@ -113,16 +113,16 @@ static const builtin_info_t Arguments_info = {
};
static HRESULT create_arguments(script_ctx_t *ctx, IDispatch *calee, DISPPARAMS *dp,
jsexcept_t *ei, IServiceProvider *caller, DispatchEx **ret)
jsexcept_t *ei, IServiceProvider *caller, jsdisp_t **ret)
{
DispatchEx *args;
jsdisp_t *args;
VARIANT var;
DWORD i;
HRESULT hres;
static const WCHAR caleeW[] = {'c','a','l','l','e','e',0};
args = heap_alloc_zero(sizeof(DispatchEx));
args = heap_alloc_zero(sizeof(jsdisp_t));
if(!args)
return E_OUTOFMEMORY;
......@@ -159,10 +159,10 @@ static HRESULT create_arguments(script_ctx_t *ctx, IDispatch *calee, DISPPARAMS
return S_OK;
}
static HRESULT create_var_disp(script_ctx_t *ctx, FunctionInstance *function, DispatchEx *arg_disp,
DISPPARAMS *dp, jsexcept_t *ei, IServiceProvider *caller, DispatchEx **ret)
static HRESULT create_var_disp(script_ctx_t *ctx, FunctionInstance *function, jsdisp_t *arg_disp,
DISPPARAMS *dp, jsexcept_t *ei, IServiceProvider *caller, jsdisp_t **ret)
{
DispatchEx *var_disp;
jsdisp_t *var_disp;
VARIANT var;
HRESULT hres;
......@@ -187,7 +187,7 @@ static HRESULT create_var_disp(script_ctx_t *ctx, FunctionInstance *function, Di
static HRESULT invoke_source(script_ctx_t *ctx, FunctionInstance *function, IDispatch *this_obj, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller)
{
DispatchEx *var_disp, *arg_disp;
jsdisp_t *var_disp, *arg_disp;
exec_ctx_t *exec_ctx;
scope_chain_t *scope;
HRESULT hres;
......@@ -215,7 +215,7 @@ static HRESULT invoke_source(script_ctx_t *ctx, FunctionInstance *function, IDis
}
jsdisp_release(var_disp);
if(SUCCEEDED(hres)) {
DispatchEx *prev_args;
jsdisp_t *prev_args;
prev_args = function->arguments;
function->arguments = arg_disp;
......@@ -232,7 +232,7 @@ static HRESULT invoke_source(script_ctx_t *ctx, FunctionInstance *function, IDis
static HRESULT invoke_constructor(script_ctx_t *ctx, FunctionInstance *function, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller)
{
DispatchEx *this_obj;
jsdisp_t *this_obj;
VARIANT var;
HRESULT hres;
......@@ -359,7 +359,7 @@ static HRESULT Function_toString(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags,
return S_OK;
}
static HRESULT array_to_args(script_ctx_t *ctx, DispatchEx *arg_array, jsexcept_t *ei, IServiceProvider *caller,
static HRESULT array_to_args(script_ctx_t *ctx, jsdisp_t *arg_array, jsexcept_t *ei, IServiceProvider *caller,
DISPPARAMS *args)
{
VARIANT var, *argv;
......@@ -422,7 +422,7 @@ static HRESULT Function_apply(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DI
}
if(argc >= 2) {
DispatchEx *arg_array = NULL;
jsdisp_t *arg_array = NULL;
if(V_VT(get_arg(dp,1)) == VT_DISPATCH) {
arg_array = iface_to_jsdisp((IUnknown*)V_DISPATCH(get_arg(dp,1)));
......@@ -566,7 +566,7 @@ static HRESULT Function_arguments(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags
return hres;
}
static void Function_destructor(DispatchEx *dispex)
static void Function_destructor(jsdisp_t *dispex)
{
FunctionInstance *This = (FunctionInstance*)dispex;
......@@ -595,7 +595,7 @@ static const builtin_info_t Function_info = {
};
static HRESULT create_function(script_ctx_t *ctx, const builtin_info_t *builtin_info, DWORD flags,
BOOL funcprot, DispatchEx *prototype, FunctionInstance **ret)
BOOL funcprot, jsdisp_t *prototype, FunctionInstance **ret)
{
FunctionInstance *function;
HRESULT hres;
......@@ -620,7 +620,7 @@ static HRESULT create_function(script_ctx_t *ctx, const builtin_info_t *builtin_
return S_OK;
}
static HRESULT set_prototype(script_ctx_t *ctx, DispatchEx *dispex, DispatchEx *prototype)
static HRESULT set_prototype(script_ctx_t *ctx, jsdisp_t *dispex, jsdisp_t *prototype)
{
jsexcept_t jsexcept;
VARIANT var;
......@@ -633,7 +633,7 @@ static HRESULT set_prototype(script_ctx_t *ctx, DispatchEx *dispex, DispatchEx *
}
HRESULT create_builtin_function(script_ctx_t *ctx, builtin_invoke_t value_proc, const WCHAR *name,
const builtin_info_t *builtin_info, DWORD flags, DispatchEx *prototype, DispatchEx **ret)
const builtin_info_t *builtin_info, DWORD flags, jsdisp_t *prototype, jsdisp_t **ret)
{
FunctionInstance *function;
HRESULT hres;
......@@ -665,10 +665,10 @@ HRESULT create_builtin_function(script_ctx_t *ctx, builtin_invoke_t value_proc,
}
HRESULT create_source_function(parser_ctx_t *ctx, parameter_t *parameters, source_elements_t *source,
scope_chain_t *scope_chain, const WCHAR *src_str, DWORD src_len, DispatchEx **ret)
scope_chain_t *scope_chain, const WCHAR *src_str, DWORD src_len, jsdisp_t **ret)
{
FunctionInstance *function;
DispatchEx *prototype;
jsdisp_t *prototype;
parameter_t *iter;
DWORD length = 0;
HRESULT hres;
......@@ -715,7 +715,7 @@ static HRESULT construct_function(script_ctx_t *ctx, DISPPARAMS *dp, jsexcept_t
WCHAR *str = NULL, *ptr;
DWORD argc, len = 0, l;
parser_ctx_t *parser;
DispatchEx *function;
jsdisp_t *function;
BSTR *params = NULL;
int i=0, j=0;
HRESULT hres = S_OK;
......@@ -834,7 +834,7 @@ static HRESULT FunctionProt_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags
return E_NOTIMPL;
}
HRESULT init_function_constr(script_ctx_t *ctx, DispatchEx *object_prototype)
HRESULT init_function_constr(script_ctx_t *ctx, jsdisp_t *object_prototype)
{
FunctionInstance *prot, *constr;
HRESULT hres;
......
......@@ -106,7 +106,7 @@ static WCHAR int_to_char(int i)
return 'A'+i-10;
}
static HRESULT constructor_call(DispatchEx *constr, WORD flags, DISPPARAMS *dp,
static HRESULT constructor_call(jsdisp_t *constr, WORD flags, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp)
{
if(flags != DISPATCH_PROPERTYGET)
......@@ -1063,7 +1063,7 @@ static const builtin_info_t JSGlobal_info = {
NULL
};
static HRESULT init_constructors(script_ctx_t *ctx, DispatchEx *object_prototype)
static HRESULT init_constructors(script_ctx_t *ctx, jsdisp_t *object_prototype)
{
HRESULT hres;
......@@ -1112,7 +1112,7 @@ static HRESULT init_constructors(script_ctx_t *ctx, DispatchEx *object_prototype
HRESULT init_global(script_ctx_t *ctx)
{
DispatchEx *math, *object_prototype;
jsdisp_t *math, *object_prototype;
VARIANT var;
HRESULT hres;
......
......@@ -758,7 +758,7 @@ static HRESULT WINAPI JScriptParseProcedure_ParseProcedureText(IActiveScriptPars
{
JScript *This = ASPARSEPROC_THIS(iface);
parser_ctx_t *parser_ctx;
DispatchEx *dispex;
jsdisp_t *dispex;
HRESULT hres;
TRACE("(%p)->(%s %s %s %s %p %s %s %u %x %p)\n", This, debugstr_w(pstrCode), debugstr_w(pstrFormalParams),
......
......@@ -193,7 +193,7 @@ HRESULT to_primitive(script_ctx_t *ctx, VARIANT *v, jsexcept_t *ei, VARIANT *ret
V_BSTR(ret) = SysAllocString(V_BSTR(v));
break;
case VT_DISPATCH: {
DispatchEx *jsdisp;
jsdisp_t *jsdisp;
DISPID id;
DISPPARAMS dp = {NULL, NULL, 0, 0};
HRESULT hres;
......@@ -593,7 +593,7 @@ HRESULT to_string(script_ctx_t *ctx, VARIANT *v, jsexcept_t *ei, BSTR *str)
/* ECMA-262 3rd Edition 9.9 */
HRESULT to_object(script_ctx_t *ctx, VARIANT *v, IDispatch **disp)
{
DispatchEx *dispex;
jsdisp_t *dispex;
HRESULT hres;
switch(V_VT(v)) {
......@@ -617,7 +617,7 @@ HRESULT to_object(script_ctx_t *ctx, VARIANT *v, IDispatch **disp)
IDispatch_AddRef(V_DISPATCH(v));
*disp = V_DISPATCH(v);
}else {
DispatchEx *obj;
jsdisp_t *obj;
hres = create_object(ctx, NULL, &obj);
if(FAILED(hres))
......
......@@ -517,9 +517,9 @@ static const builtin_info_t Math_info = {
NULL
};
HRESULT create_math(script_ctx_t *ctx, DispatchEx **ret)
HRESULT create_math(script_ctx_t *ctx, jsdisp_t **ret)
{
DispatchEx *math;
jsdisp_t *math;
unsigned i;
VARIANT v;
HRESULT hres;
......@@ -538,7 +538,7 @@ HRESULT create_math(script_ctx_t *ctx, DispatchEx **ret)
{SQRT2W, M_SQRT2}, /* ECMA-262 3rd Edition 15.8.1.8 */
};
math = heap_alloc_zero(sizeof(DispatchEx));
math = heap_alloc_zero(sizeof(jsdisp_t));
if(!math)
return E_OUTOFMEMORY;
......
......@@ -28,7 +28,7 @@
WINE_DEFAULT_DEBUG_CHANNEL(jscript);
typedef struct {
DispatchEx dispex;
jsdisp_t dispex;
VARIANT num;
} NumberInstance;
......@@ -287,7 +287,7 @@ static HRESULT NumberConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags
break;
case DISPATCH_CONSTRUCT: {
DispatchEx *obj;
jsdisp_t *obj;
if(arg_cnt(dp)) {
hres = to_number(ctx, get_arg(dp, 0), ei, &num);
......@@ -314,7 +314,7 @@ static HRESULT NumberConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags
return S_OK;
}
static HRESULT alloc_number(script_ctx_t *ctx, DispatchEx *object_prototype, NumberInstance **ret)
static HRESULT alloc_number(script_ctx_t *ctx, jsdisp_t *object_prototype, NumberInstance **ret)
{
NumberInstance *number;
HRESULT hres;
......@@ -334,7 +334,7 @@ static HRESULT alloc_number(script_ctx_t *ctx, DispatchEx *object_prototype, Num
return S_OK;
}
HRESULT create_number_constr(script_ctx_t *ctx, DispatchEx *object_prototype, DispatchEx **ret)
HRESULT create_number_constr(script_ctx_t *ctx, jsdisp_t *object_prototype, jsdisp_t **ret)
{
NumberInstance *number;
HRESULT hres;
......@@ -353,7 +353,7 @@ HRESULT create_number_constr(script_ctx_t *ctx, DispatchEx *object_prototype, Di
return hres;
}
HRESULT create_number(script_ctx_t *ctx, VARIANT *num, DispatchEx **ret)
HRESULT create_number(script_ctx_t *ctx, VARIANT *num, jsdisp_t **ret)
{
NumberInstance *number;
HRESULT hres;
......
......@@ -35,7 +35,7 @@ static const WCHAR default_valueW[] = {'[','o','b','j','e','c','t',' ','O','b','
static HRESULT Object_toString(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp)
{
DispatchEx *jsdisp;
jsdisp_t *jsdisp;
const WCHAR *str;
static const WCHAR formatW[] = {'[','o','b','j','e','c','t',' ','%','s',']',0};
......@@ -151,7 +151,7 @@ static HRESULT Object_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DISP
return S_OK;
}
static void Object_destructor(DispatchEx *dispex)
static void Object_destructor(jsdisp_t *dispex)
{
heap_free(dispex);
}
......@@ -204,7 +204,7 @@ static HRESULT ObjectConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags
}
/* fall through */
case DISPATCH_CONSTRUCT: {
DispatchEx *obj;
jsdisp_t *obj;
hres = create_object(ctx, NULL, &obj);
if(FAILED(hres))
......@@ -223,7 +223,7 @@ static HRESULT ObjectConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags
return S_OK;
}
HRESULT create_object_constr(script_ctx_t *ctx, DispatchEx *object_prototype, DispatchEx **ret)
HRESULT create_object_constr(script_ctx_t *ctx, jsdisp_t *object_prototype, jsdisp_t **ret)
{
static const WCHAR ObjectW[] = {'O','b','j','e','c','t',0};
......@@ -231,17 +231,17 @@ HRESULT create_object_constr(script_ctx_t *ctx, DispatchEx *object_prototype, Di
object_prototype, ret);
}
HRESULT create_object_prototype(script_ctx_t *ctx, DispatchEx **ret)
HRESULT create_object_prototype(script_ctx_t *ctx, jsdisp_t **ret)
{
return create_dispex(ctx, &Object_info, NULL, ret);
}
HRESULT create_object(script_ctx_t *ctx, DispatchEx *constr, DispatchEx **ret)
HRESULT create_object(script_ctx_t *ctx, jsdisp_t *constr, jsdisp_t **ret)
{
DispatchEx *object;
jsdisp_t *object;
HRESULT hres;
object = heap_alloc_zero(sizeof(DispatchEx));
object = heap_alloc_zero(sizeof(jsdisp_t));
if(!object)
return E_OUTOFMEMORY;
......
......@@ -79,7 +79,7 @@ typedef struct {
} JSRegExp;
typedef struct {
DispatchEx dispex;
jsdisp_t dispex;
JSRegExp *jsregexp;
BSTR str;
......@@ -3404,7 +3404,7 @@ static HRESULT do_regexp_match_next(script_ctx_t *ctx, RegExpInstance *regexp, D
return S_OK;
}
HRESULT regexp_match_next(script_ctx_t *ctx, DispatchEx *dispex, DWORD rem_flags, const WCHAR *str,
HRESULT regexp_match_next(script_ctx_t *ctx, jsdisp_t *dispex, DWORD rem_flags, const WCHAR *str,
DWORD len, const WCHAR **cp, match_result_t **parens, DWORD *parens_size, DWORD *parens_cnt,
match_result_t *ret)
{
......@@ -3423,7 +3423,7 @@ HRESULT regexp_match_next(script_ctx_t *ctx, DispatchEx *dispex, DWORD rem_flags
return hres;
}
HRESULT regexp_match(script_ctx_t *ctx, DispatchEx *dispex, const WCHAR *str, DWORD len, BOOL gflag,
HRESULT regexp_match(script_ctx_t *ctx, jsdisp_t *dispex, const WCHAR *str, DWORD len, BOOL gflag,
match_result_t **match_result, DWORD *result_cnt)
{
RegExpInstance *This = (RegExpInstance*)dispex;
......@@ -3583,7 +3583,7 @@ static HRESULT RegExp_toString(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, D
static HRESULT create_match_array(script_ctx_t *ctx, BSTR input, const match_result_t *result,
const match_result_t *parens, DWORD parens_cnt, jsexcept_t *ei, IDispatch **ret)
{
DispatchEx *array;
jsdisp_t *array;
VARIANT var;
int i;
HRESULT hres = S_OK;
......@@ -3781,7 +3781,7 @@ static HRESULT RegExp_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DISP
return S_OK;
}
static void RegExp_destructor(DispatchEx *dispex)
static void RegExp_destructor(jsdisp_t *dispex)
{
RegExpInstance *This = (RegExpInstance*)dispex;
......@@ -3812,7 +3812,7 @@ static const builtin_info_t RegExp_info = {
NULL
};
static HRESULT alloc_regexp(script_ctx_t *ctx, DispatchEx *object_prototype, RegExpInstance **ret)
static HRESULT alloc_regexp(script_ctx_t *ctx, jsdisp_t *object_prototype, RegExpInstance **ret)
{
RegExpInstance *regexp;
HRESULT hres;
......@@ -3835,7 +3835,7 @@ static HRESULT alloc_regexp(script_ctx_t *ctx, DispatchEx *object_prototype, Reg
return S_OK;
}
HRESULT create_regexp(script_ctx_t *ctx, const WCHAR *exp, int len, DWORD flags, DispatchEx **ret)
HRESULT create_regexp(script_ctx_t *ctx, const WCHAR *exp, int len, DWORD flags, jsdisp_t **ret)
{
RegExpInstance *regexp;
HRESULT hres;
......@@ -3869,14 +3869,14 @@ HRESULT create_regexp(script_ctx_t *ctx, const WCHAR *exp, int len, DWORD flags,
return S_OK;
}
HRESULT create_regexp_var(script_ctx_t *ctx, VARIANT *src_arg, VARIANT *flags_arg, DispatchEx **ret)
HRESULT create_regexp_var(script_ctx_t *ctx, VARIANT *src_arg, VARIANT *flags_arg, jsdisp_t **ret)
{
const WCHAR *opt = emptyW, *src;
DWORD flags;
HRESULT hres;
if(V_VT(src_arg) == VT_DISPATCH) {
DispatchEx *obj;
jsdisp_t *obj;
obj = iface_to_jsdisp((IUnknown*)V_DISPATCH(src_arg));
if(obj) {
......@@ -3915,13 +3915,13 @@ HRESULT create_regexp_var(script_ctx_t *ctx, VARIANT *src_arg, VARIANT *flags_ar
return create_regexp(ctx, src, -1, flags, ret);
}
HRESULT regexp_string_match(script_ctx_t *ctx, DispatchEx *re, BSTR str,
HRESULT regexp_string_match(script_ctx_t *ctx, jsdisp_t *re, BSTR str,
VARIANT *retv, jsexcept_t *ei)
{
RegExpInstance *regexp = (RegExpInstance*)re;
match_result_t *match_result;
DWORD match_cnt, i, length;
DispatchEx *array;
jsdisp_t *array;
VARIANT var;
HRESULT hres;
......@@ -4058,7 +4058,7 @@ static HRESULT RegExpConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags
if(arg_cnt(dp)) {
VARIANT *arg = get_arg(dp,0);
if(V_VT(arg) == VT_DISPATCH) {
DispatchEx *jsdisp = iface_to_jsdisp((IUnknown*)V_DISPATCH(arg));
jsdisp_t *jsdisp = iface_to_jsdisp((IUnknown*)V_DISPATCH(arg));
if(jsdisp) {
if(is_class(jsdisp, JSCLASS_REGEXP)) {
if(arg_cnt(dp) > 1 && V_VT(get_arg(dp,1)) != VT_EMPTY) {
......@@ -4080,7 +4080,7 @@ static HRESULT RegExpConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags
}
/* fall through */
case DISPATCH_CONSTRUCT: {
DispatchEx *ret;
jsdisp_t *ret;
HRESULT hres;
if(!arg_cnt(dp)) {
......@@ -4122,7 +4122,7 @@ static const builtin_info_t RegExpConstr_info = {
NULL
};
HRESULT create_regexp_constr(script_ctx_t *ctx, DispatchEx *object_prototype, DispatchEx **ret)
HRESULT create_regexp_constr(script_ctx_t *ctx, jsdisp_t *object_prototype, jsdisp_t **ret)
{
RegExpInstance *regexp;
HRESULT hres;
......
......@@ -23,7 +23,7 @@
WINE_DEFAULT_DEBUG_CHANNEL(jscript);
typedef struct {
DispatchEx dispex;
jsdisp_t dispex;
WCHAR *str;
DWORD length;
......@@ -622,7 +622,7 @@ static HRESULT String_match(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DISP
VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp)
{
const WCHAR *str;
DispatchEx *regexp;
jsdisp_t *regexp;
VARIANT *arg_var;
DWORD length;
BSTR val_str = NULL;
......@@ -710,7 +710,7 @@ static HRESULT strbuf_append(strbuf_t *buf, const WCHAR *str, DWORD len)
return S_OK;
}
static HRESULT rep_call(script_ctx_t *ctx, DispatchEx *func, const WCHAR *str, match_result_t *match,
static HRESULT rep_call(script_ctx_t *ctx, jsdisp_t *func, const WCHAR *str, match_result_t *match,
match_result_t *parens, DWORD parens_cnt, BSTR *ret, jsexcept_t *ei, IServiceProvider *caller)
{
DISPPARAMS dp = {NULL, NULL, 0, 0};
......@@ -778,7 +778,7 @@ static HRESULT String_replace(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DI
const WCHAR *str;
DWORD parens_cnt = 0, parens_size=0, rep_len=0, length;
BSTR rep_str = NULL, match_str = NULL, ret_str, val_str;
DispatchEx *rep_func = NULL, *regexp = NULL;
jsdisp_t *rep_func = NULL, *regexp = NULL;
match_result_t *parens = NULL, match = {NULL,0}, **parens_ptr = &parens;
strbuf_t ret = {NULL,0,0};
DWORD re_flags = REM_NO_CTX_UPDATE;
......@@ -1008,7 +1008,7 @@ static HRESULT String_replace(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DI
static HRESULT String_search(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *sp)
{
DispatchEx *regexp = NULL;
jsdisp_t *regexp = NULL;
const WCHAR *str, *cp;
match_result_t match;
VARIANT *arg;
......@@ -1158,7 +1158,7 @@ static HRESULT String_split(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DISP
const WCHAR *str, *ptr, *ptr2;
BOOL use_regexp = FALSE;
VARIANT *arg, var;
DispatchEx *array;
jsdisp_t *array;
BSTR val_str, match_str = NULL;
HRESULT hres;
......@@ -1176,7 +1176,7 @@ static HRESULT String_split(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DISP
arg = get_arg(dp, 0);
switch(V_VT(arg)) {
case VT_DISPATCH: {
DispatchEx *regexp;
jsdisp_t *regexp;
regexp = iface_to_jsdisp((IUnknown*)V_DISPATCH(arg));
if(regexp) {
......@@ -1546,7 +1546,7 @@ static HRESULT String_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags, DISP
return S_OK;
}
static void String_destructor(DispatchEx *dispex)
static void String_destructor(jsdisp_t *dispex)
{
StringInstance *This = (StringInstance*)dispex;
......@@ -1656,7 +1656,7 @@ static HRESULT StringConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags
break;
}
case DISPATCH_CONSTRUCT: {
DispatchEx *ret;
jsdisp_t *ret;
if(arg_cnt(dp)) {
BSTR str;
......@@ -1687,7 +1687,7 @@ static HRESULT StringConstr_value(script_ctx_t *ctx, vdisp_t *jsthis, WORD flags
return S_OK;
}
static HRESULT string_alloc(script_ctx_t *ctx, DispatchEx *object_prototype, StringInstance **ret)
static HRESULT string_alloc(script_ctx_t *ctx, jsdisp_t *object_prototype, StringInstance **ret)
{
StringInstance *string;
HRESULT hres;
......@@ -1722,7 +1722,7 @@ static const builtin_info_t StringConstr_info = {
NULL
};
HRESULT create_string_constr(script_ctx_t *ctx, DispatchEx *object_prototype, DispatchEx **ret)
HRESULT create_string_constr(script_ctx_t *ctx, jsdisp_t *object_prototype, jsdisp_t **ret)
{
StringInstance *string;
HRESULT hres;
......@@ -1740,7 +1740,7 @@ HRESULT create_string_constr(script_ctx_t *ctx, DispatchEx *object_prototype, Di
return hres;
}
HRESULT create_string(script_ctx_t *ctx, const WCHAR *str, DWORD len, DispatchEx **ret)
HRESULT create_string(script_ctx_t *ctx, const WCHAR *str, DWORD len, jsdisp_t **ret)
{
StringInstance *string;
HRESULT hres;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment