Commit d43ab58e authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

mshtml: Use DISPATCH_* macros instead of INVOKE_*.

parent f6b89e9f
...@@ -221,7 +221,7 @@ static void add_func_info(dispex_data_t *data, DWORD *size, tid_t tid, const FUN ...@@ -221,7 +221,7 @@ static void add_func_info(dispex_data_t *data, DWORD *size, tid_t tid, const FUN
data->funcs[data->func_cnt].id = desc->memid; data->funcs[data->func_cnt].id = desc->memid;
data->funcs[data->func_cnt].tid = tid; data->funcs[data->func_cnt].tid = tid;
data->funcs[data->func_cnt].func_disp_idx = desc->invkind == INVOKE_FUNC ? data->func_disp_cnt++ : -1; data->funcs[data->func_cnt].func_disp_idx = desc->invkind == DISPATCH_METHOD ? data->func_disp_cnt++ : -1;
data->func_cnt++; data->func_cnt++;
} }
...@@ -572,6 +572,7 @@ static HRESULT function_invoke(DispatchEx *This, func_info_t *func, WORD flags, ...@@ -572,6 +572,7 @@ static HRESULT function_invoke(DispatchEx *This, func_info_t *func, WORD flags,
switch(flags) { switch(flags) {
case DISPATCH_METHOD: case DISPATCH_METHOD:
case DISPATCH_METHOD|DISPATCH_PROPERTYGET:
hres = typeinfo_invoke(This, func, flags, dp, res, ei); hres = typeinfo_invoke(This, func, flags, dp, res, ei);
break; break;
case DISPATCH_PROPERTYGET: { case DISPATCH_PROPERTYGET: {
...@@ -809,7 +810,7 @@ static HRESULT WINAPI DispatchEx_InvokeEx(IDispatchEx *iface, DISPID id, LCID lc ...@@ -809,7 +810,7 @@ static HRESULT WINAPI DispatchEx_InvokeEx(IDispatchEx *iface, DISPID id, LCID lc
var = &This->dynamic_data->props[idx].var; var = &This->dynamic_data->props[idx].var;
switch(wFlags) { switch(wFlags) {
case INVOKE_FUNC: { case DISPATCH_METHOD: {
DISPID named_arg = DISPID_THIS; DISPID named_arg = DISPID_THIS;
DISPPARAMS dp = {NULL, &named_arg, 0, 1}; DISPPARAMS dp = {NULL, &named_arg, 0, 1};
IDispatchEx *dispex; IDispatchEx *dispex;
...@@ -848,9 +849,9 @@ static HRESULT WINAPI DispatchEx_InvokeEx(IDispatchEx *iface, DISPID id, LCID lc ...@@ -848,9 +849,9 @@ static HRESULT WINAPI DispatchEx_InvokeEx(IDispatchEx *iface, DISPID id, LCID lc
heap_free(dp.rgvarg); heap_free(dp.rgvarg);
return hres; return hres;
} }
case INVOKE_PROPERTYGET: case DISPATCH_PROPERTYGET:
return VariantCopy(pvarRes, var); return VariantCopy(pvarRes, var);
case INVOKE_PROPERTYPUT: case DISPATCH_PROPERTYPUT:
VariantClear(var); VariantClear(var);
return VariantCopy(var, pdp->rgvarg); return VariantCopy(var, pdp->rgvarg);
default: default:
......
...@@ -397,7 +397,7 @@ static HRESULT HTMLElementCollection_invoke(IUnknown *iface, DISPID id, LCID lci ...@@ -397,7 +397,7 @@ static HRESULT HTMLElementCollection_invoke(IUnknown *iface, DISPID id, LCID lci
return DISP_E_UNKNOWNNAME; return DISP_E_UNKNOWNNAME;
switch(flags) { switch(flags) {
case INVOKE_PROPERTYGET: case DISPATCH_PROPERTYGET:
V_VT(res) = VT_DISPATCH; V_VT(res) = VT_DISPATCH;
V_DISPATCH(res) = (IDispatch*)HTMLELEM(This->elems[idx]); V_DISPATCH(res) = (IDispatch*)HTMLELEM(This->elems[idx]);
IHTMLElement_AddRef(HTMLELEM(This->elems[idx])); IHTMLElement_AddRef(HTMLELEM(This->elems[idx]));
......
...@@ -208,7 +208,7 @@ static HRESULT HTMLDOMChildrenCollection_invoke(IUnknown *iface, DISPID id, LCID ...@@ -208,7 +208,7 @@ static HRESULT HTMLDOMChildrenCollection_invoke(IUnknown *iface, DISPID id, LCID
TRACE("(%p)->(%x %x %x %p %p %p %p)\n", This, id, lcid, flags, params, res, ei, caller); TRACE("(%p)->(%x %x %x %p %p %p %p)\n", This, id, lcid, flags, params, res, ei, caller);
switch(flags) { switch(flags) {
case INVOKE_PROPERTYGET: { case DISPATCH_PROPERTYGET: {
IDispatch *disp = NULL; IDispatch *disp = NULL;
HRESULT hres; 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