ReactOS 0.4.16-dev-329-g9223134
vbdisp.c
Go to the documentation of this file.
1/*
2 * Copyright 2011 Jacek Caban for CodeWeavers
3 *
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
8 *
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
13 *
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
17 */
18
19#include <assert.h>
20
21#include "vbscript.h"
22
23#include "wine/debug.h"
24
26
27#define FDEX_VERSION_MASK 0xf0000000
28
29static inline BOOL is_func_id(vbdisp_t *This, DISPID id)
30{
31 return id < This->desc->func_cnt;
32}
33
34static BOOL get_func_id(vbdisp_t *This, const WCHAR *name, vbdisp_invoke_type_t invoke_type, BOOL search_private, DISPID *id)
35{
36 unsigned i;
37
38 for(i = invoke_type == VBDISP_ANY ? 0 : 1; i < This->desc->func_cnt; i++) {
39 if(invoke_type == VBDISP_ANY) {
40 if(!search_private && !This->desc->funcs[i].is_public)
41 continue;
42 if(!i && !This->desc->funcs[0].name) /* default value may not exist */
43 continue;
44 }else {
45 if(!This->desc->funcs[i].entries[invoke_type]
46 || (!search_private && !This->desc->funcs[i].entries[invoke_type]->is_public))
47 continue;
48 }
49
50 if(!wcsicmp(This->desc->funcs[i].name, name)) {
51 *id = i;
52 return TRUE;
53 }
54 }
55
56 return FALSE;
57}
58
60{
61 unsigned i;
62
63 if(get_func_id(This, name, invoke_type, search_private, id))
64 return S_OK;
65
66 for(i=0; i < This->desc->prop_cnt; i++) {
67 if(!search_private && !This->desc->props[i].is_public)
68 continue;
69
70 if(!wcsicmp(This->desc->props[i].name, name)) {
71 *id = i + This->desc->func_cnt;
72 return S_OK;
73 }
74 }
75
76 *id = -1;
77 return DISP_E_UNKNOWNNAME;
78}
79
80static HRESULT get_propput_arg(script_ctx_t *ctx, const DISPPARAMS *dp, WORD flags, VARIANT *v, BOOL *is_owned)
81{
82 unsigned i;
83
84 for(i=0; i < dp->cNamedArgs; i++) {
85 if(dp->rgdispidNamedArgs[i] == DISPID_PROPERTYPUT)
86 break;
87 }
88 if(i == dp->cNamedArgs) {
89 WARN("no value to set\n");
91 }
92
93 *v = dp->rgvarg[i];
94 if(V_VT(v) == (VT_VARIANT|VT_BYREF))
95 *v = *V_VARIANTREF(v);
96 *is_owned = FALSE;
97
98 if(V_VT(v) == VT_DISPATCH) {
101
103 if(FAILED(hres))
104 return hres;
105
106 *is_owned = TRUE;
107 }
108 }else if(!(flags & DISPATCH_PROPERTYPUT)) {
109 WARN("%s can't be assigned without DISPATCH_PROPERTYPUT flag\n", debugstr_variant(v));
110 return DISP_E_EXCEPTION;
111 }
112
113 return S_OK;
114}
115
117{
119
120 switch(flags) {
123 if(dp->cArgs) {
124 WARN("called with arguments\n");
125 return DISP_E_MEMBERNOTFOUND; /* That's what tests show */
126 }
127
129 break;
130
134 VARIANT put_val;
135 BOOL own_val;
136
137 hres = get_propput_arg(ctx, dp, flags, &put_val, &own_val);
138 if(FAILED(hres))
139 return hres;
140
141 if(arg_cnt(dp)) {
142 FIXME("Arguments not supported\n");
143 return E_NOTIMPL;
144 }
145
146 if(res)
147 V_VT(res) = VT_EMPTY;
148
149 if(own_val)
150 *v = put_val;
151 else
152 hres = VariantCopyInd(v, &put_val);
153 break;
154 }
155
156 default:
157 FIXME("unimplemented flags %x\n", flags);
158 return E_NOTIMPL;
159 }
160
161 return hres;
162}
163
164static HRESULT invoke_vbdisp(vbdisp_t *This, DISPID id, DWORD flags, BOOL extern_caller, DISPPARAMS *params, VARIANT *res)
165{
166 if(id < 0)
168
169 if(is_func_id(This, id)) {
171
172 TRACE("%p->%s\n", This, debugstr_w(This->desc->funcs[id].name));
173
174 switch(flags) {
176 func = This->desc->funcs[id].entries[VBDISP_CALLGET];
177 if(!func || (func->type != FUNC_PROPGET && func->type != FUNC_DEFGET)) {
178 WARN("no getter\n");
180 }
181
182 return exec_script(This->desc->ctx, extern_caller, func, This, params, res);
183
184 case DISPATCH_METHOD:
186 func = This->desc->funcs[id].entries[VBDISP_CALLGET];
187 if(!func) {
188 FIXME("no invoke/getter\n");
190 }
191
192 return exec_script(This->desc->ctx, extern_caller, func, This, params, res);
193
197 DISPPARAMS dp = {NULL, NULL, 1, 0};
198 BOOL needs_release;
199 VARIANT put_val;
201
202 if(arg_cnt(params)) {
203 FIXME("arguments not implemented\n");
204 return E_NOTIMPL;
205 }
206
207 hres = get_propput_arg(This->desc->ctx, params, flags, &put_val, &needs_release);
208 if(FAILED(hres))
209 return hres;
210
211 dp.rgvarg = &put_val;
212 func = This->desc->funcs[id].entries[V_VT(&put_val) == VT_DISPATCH ? VBDISP_SET : VBDISP_LET];
213 if(!func) {
214 FIXME("no letter/setter\n");
216 }
217
218 hres = exec_script(This->desc->ctx, extern_caller, func, This, &dp, NULL);
219 if(needs_release)
220 VariantClear(&put_val);
221 return hres;
222 }
223 default:
224 FIXME("flags %x\n", flags);
226 }
227 }
228
229 if(id >= This->desc->prop_cnt + This->desc->func_cnt)
231
232 TRACE("%p->%s\n", This, debugstr_w(This->desc->props[id - This->desc->func_cnt].name));
233 return invoke_variant_prop(This->desc->ctx, This->props+(id-This->desc->func_cnt), flags, params, res);
234}
235
237{
238 DISPPARAMS dp = {0};
239
240 if(This->terminator_ran)
241 return TRUE;
242 This->terminator_ran = TRUE;
243
244 if(!This->desc->class_terminate_id)
245 return TRUE;
246
247 This->ref++;
248 exec_script(This->desc->ctx, FALSE, This->desc->funcs[This->desc->class_terminate_id].entries[VBDISP_CALLGET],
249 This, &dp, NULL);
250 return !--This->ref;
251}
252
254{
255 unsigned i;
256
257 if(!This->desc)
258 return;
259
260 for(i=0; i < This->desc->array_cnt; i++) {
261 if(This->arrays[i]) {
262 SafeArrayDestroy(This->arrays[i]);
263 This->arrays[i] = NULL;
264 }
265 }
266
267 for(i=0; i < This->desc->prop_cnt; i++)
268 VariantClear(This->props+i);
269}
270
272{
273 return CONTAINING_RECORD(iface, vbdisp_t, IDispatchEx_iface);
274}
275
277{
279
281 TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv);
282 *ppv = &This->IDispatchEx_iface;
283 }else if(IsEqualGUID(&IID_IDispatch, riid)) {
284 TRACE("(%p)->(IID_IDispatch %p)\n", This, ppv);
285 *ppv = &This->IDispatchEx_iface;
286 }else if(IsEqualGUID(&IID_IDispatchEx, riid)) {
287 TRACE("(%p)->(IID_IDispatchEx %p)\n", This, ppv);
288 *ppv = &This->IDispatchEx_iface;
289 }else {
290 WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv);
291 *ppv = NULL;
292 return E_NOINTERFACE;
293 }
294
295 IUnknown_AddRef((IUnknown*)*ppv);
296 return S_OK;
297}
298
300{
303
304 TRACE("(%p) ref=%d\n", This, ref);
305
306 return ref;
307}
308
310{
313
314 TRACE("(%p) ref=%d\n", This, ref);
315
316 if(!ref && run_terminator(This)) {
318 list_remove(&This->entry);
319 heap_free(This->arrays);
321 }
322
323 return ref;
324}
325
327{
329
330 TRACE("(%p)->(%p)\n", This, pctinfo);
331
332 *pctinfo = 1;
333 return S_OK;
334}
335
337 ITypeInfo **ppTInfo)
338{
340 FIXME("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo);
341 return E_NOTIMPL;
342}
343
345 LPOLESTR *rgszNames, UINT cNames, LCID lcid,
346 DISPID *rgDispId)
347{
349 FIXME("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames,
350 lcid, rgDispId);
351 return E_NOTIMPL;
352}
353
355 REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams,
356 VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
357{
359
360 TRACE("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid),
361 lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
362
363 return IDispatchEx_InvokeEx(&This->IDispatchEx_iface, dispIdMember, lcid, wFlags, pDispParams, pVarResult, pExcepInfo, NULL);
364}
365
367{
369
370 TRACE("(%p)->(%s %x %p)\n", This, debugstr_w(bstrName), grfdex, pid);
371
372 grfdex &= ~FDEX_VERSION_MASK;
373
374 if(!This->desc)
375 return E_UNEXPECTED;
376
377 /* Tests show that fdexNameCaseSensitive is ignored */
378
379 if(grfdex & ~(fdexNameEnsure|fdexNameCaseInsensitive|fdexNameCaseSensitive)) {
380 FIXME("unsupported flags %x\n", grfdex);
381 return E_NOTIMPL;
382 }
383
384 return vbdisp_get_id(This, bstrName, VBDISP_ANY, FALSE, pid);
385}
386
387static HRESULT WINAPI DispatchEx_InvokeEx(IDispatchEx *iface, DISPID id, LCID lcid, WORD wFlags, DISPPARAMS *pdp,
388 VARIANT *pvarRes, EXCEPINFO *pei, IServiceProvider *pspCaller)
389{
391
392 TRACE("(%p)->(%x %x %x %p %p %p %p)\n", This, id, lcid, wFlags, pdp, pvarRes, pei, pspCaller);
393
394 if(!This->desc)
395 return E_UNEXPECTED;
396
397 if(pvarRes)
398 V_VT(pvarRes) = VT_EMPTY;
399
400 return invoke_vbdisp(This, id, wFlags, TRUE, pdp, pvarRes);
401}
402
404{
406 FIXME("(%p)->(%s %x)\n", This, debugstr_w(bstrName), grfdex);
407 return E_NOTIMPL;
408}
409
411{
413 FIXME("(%p)->(%x)\n", This, id);
414 return E_NOTIMPL;
415}
416
418{
420 FIXME("(%p)->(%x %x %p)\n", This, id, grfdexFetch, pgrfdex);
421 return E_NOTIMPL;
422}
423
425{
427 FIXME("(%p)->(%x %p)\n", This, id, pbstrName);
428 return E_NOTIMPL;
429}
430
432{
434 FIXME("(%p)->(%x %x %p)\n", This, grfdex, id, pid);
435 return E_NOTIMPL;
436}
437
439{
441 FIXME("(%p)->(%p)\n", This, ppunk);
442 return E_NOTIMPL;
443}
444
445static IDispatchExVtbl DispatchExVtbl = {
461};
462
464{
465 return iface->lpVtbl == (IDispatchVtbl*)&DispatchExVtbl
466 ? CONTAINING_RECORD((IDispatchEx *)iface, vbdisp_t, IDispatchEx_iface)
467 : NULL;
468}
469
471{
472 vbdisp_t *vbdisp;
473 HRESULT hres = S_OK;
474
475 vbdisp = heap_alloc_zero( FIELD_OFFSET( vbdisp_t, props[desc->prop_cnt] ));
476 if(!vbdisp)
477 return E_OUTOFMEMORY;
478
479 vbdisp->IDispatchEx_iface.lpVtbl = &DispatchExVtbl;
480 vbdisp->ref = 1;
481 vbdisp->desc = desc;
482
483 list_add_tail(&desc->ctx->objects, &vbdisp->entry);
484
485 if(desc->array_cnt) {
486 vbdisp->arrays = heap_alloc_zero(desc->array_cnt * sizeof(*vbdisp->arrays));
487 if(vbdisp->arrays) {
488 unsigned i, j;
489
490 for(i=0; i < desc->array_cnt; i++) {
491 if(!desc->array_descs[i].dim_cnt)
492 continue;
493
494 vbdisp->arrays[i] = SafeArrayCreate(VT_VARIANT, desc->array_descs[i].dim_cnt, desc->array_descs[i].bounds);
495 if(!vbdisp->arrays[i]) {
497 break;
498 }
499 }
500
501 if(SUCCEEDED(hres)) {
502 for(i=0, j=0; i < desc->prop_cnt; i++) {
503 if(desc->props[i].is_array) {
505 V_ARRAYREF(vbdisp->props+i) = vbdisp->arrays + j++;
506 }
507 }
508 }
509 }else {
511 }
512 }
513
514 if(SUCCEEDED(hres) && desc->class_initialize_id) {
515 DISPPARAMS dp = {0};
516 hres = exec_script(desc->ctx, FALSE, desc->funcs[desc->class_initialize_id].entries[VBDISP_CALLGET],
517 vbdisp, &dp, NULL);
518 }
519
520 if(FAILED(hres)) {
521 IDispatchEx_Release(&vbdisp->IDispatchEx_iface);
522 return hres;
523 }
524
525 *ret = vbdisp;
526 return S_OK;
527}
528
530 const WCHAR *name;
532 union {
535 } u;
536};
537
539{
540 return (ident-This->ident_map)+1;
541}
542
544{
545 return 0 < id && id <= This->ident_map_cnt ? This->ident_map+id-1 : NULL;
546}
547
549{
551
552 if(!This->ident_map_size) {
553 This->ident_map = heap_alloc(4 * sizeof(*This->ident_map));
554 if(!This->ident_map)
555 return NULL;
556 This->ident_map_size = 4;
557 }else if(This->ident_map_cnt == This->ident_map_size) {
558 ident_map_t *new_map;
559
560 new_map = heap_realloc(This->ident_map, 2*This->ident_map_size*sizeof(*new_map));
561 if(!new_map)
562 return NULL;
563 This->ident_map = new_map;
564 This->ident_map_size *= 2;
565 }
566
567 ret = This->ident_map + This->ident_map_cnt++;
568 ret->name = name;
569 return ret;
570}
571
573{
574 return CONTAINING_RECORD(iface, ScriptDisp, IDispatchEx_iface);
575}
576
578{
580
582 TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv);
583 *ppv = &This->IDispatchEx_iface;
584 }else if(IsEqualGUID(&IID_IDispatch, riid)) {
585 TRACE("(%p)->(IID_IDispatch %p)\n", This, ppv);
586 *ppv = &This->IDispatchEx_iface;
587 }else if(IsEqualGUID(&IID_IDispatchEx, riid)) {
588 TRACE("(%p)->(IID_IDispatchEx %p)\n", This, ppv);
589 *ppv = &This->IDispatchEx_iface;
590 }else {
591 WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv);
592 *ppv = NULL;
593 return E_NOINTERFACE;
594 }
595
596 IUnknown_AddRef((IUnknown*)*ppv);
597 return S_OK;
598}
599
601{
604
605 TRACE("(%p) ref=%d\n", This, ref);
606
607 return ref;
608}
609
611{
614
615 TRACE("(%p) ref=%d\n", This, ref);
616
617 if(!ref) {
618 assert(!This->ctx);
619 heap_free(This->ident_map);
621 }
622
623 return ref;
624}
625
627{
629
630 TRACE("(%p)->(%p)\n", This, pctinfo);
631
632 *pctinfo = 1;
633 return S_OK;
634}
635
637 ITypeInfo **ppTInfo)
638{
640 FIXME("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo);
641 return E_NOTIMPL;
642}
643
645 LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId)
646{
648 UINT i;
650
651 TRACE("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames,
652 lcid, rgDispId);
653
654 for(i=0; i < cNames; i++) {
655 hres = IDispatchEx_GetDispID(&This->IDispatchEx_iface, rgszNames[i], 0, rgDispId+i);
656 if(FAILED(hres))
657 return hres;
658 }
659
660 return S_OK;
661}
662
664 WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
665{
667
668 TRACE("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid),
669 lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
670
671 return IDispatchEx_InvokeEx(&This->IDispatchEx_iface, dispIdMember, lcid, wFlags,
672 pDispParams, pVarResult, pExcepInfo, NULL);
673}
674
676{
681
682 TRACE("(%p)->(%s %x %p)\n", This, debugstr_w(bstrName), grfdex, pid);
683
684 if(!This->ctx)
685 return E_UNEXPECTED;
686
687 for(ident = This->ident_map; ident < This->ident_map+This->ident_map_cnt; ident++) {
688 if(!wcsicmp(ident->name, bstrName)) {
690 return S_OK;
691 }
692 }
693
694 for(var = This->ctx->global_vars; var; var = var->next) {
695 if(!wcsicmp(var->name, bstrName)) {
696 ident = add_ident(This, var->name);
697 if(!ident)
698 return E_OUTOFMEMORY;
699
700 ident->is_var = TRUE;
701 ident->u.var = var;
703 return S_OK;
704 }
705 }
706
707 for(func = This->ctx->global_funcs; func; func = func->next) {
708 if(!wcsicmp(func->name, bstrName)) {
709 ident = add_ident(This, func->name);
710 if(!ident)
711 return E_OUTOFMEMORY;
712
713 ident->is_var = FALSE;
714 ident->u.func = func;
716 return S_OK;
717 }
718 }
719
720 *pid = -1;
721 return DISP_E_UNKNOWNNAME;
722}
723
724static HRESULT WINAPI ScriptDisp_InvokeEx(IDispatchEx *iface, DISPID id, LCID lcid, WORD wFlags, DISPPARAMS *pdp,
725 VARIANT *pvarRes, EXCEPINFO *pei, IServiceProvider *pspCaller)
726{
730
731 TRACE("(%p)->(%x %x %x %p %p %p %p)\n", This, id, lcid, wFlags, pdp, pvarRes, pei, pspCaller);
732
733 ident = id_to_ident(This, id);
734 if(!ident)
736
737 if(ident->is_var) {
738 if(ident->u.var->is_const) {
739 FIXME("const not supported\n");
740 return E_NOTIMPL;
741 }
742
743 return invoke_variant_prop(This->ctx, &ident->u.var->v, wFlags, pdp, pvarRes);
744 }
745
746 switch(wFlags) {
747 case DISPATCH_METHOD:
749 hres = exec_script(This->ctx, TRUE, ident->u.func, NULL, pdp, pvarRes);
750 break;
751 default:
752 FIXME("Unsupported flags %x\n", wFlags);
753 hres = E_NOTIMPL;
754 }
755
756 return hres;
757}
758
760{
762 FIXME("(%p)->(%s %x)\n", This, debugstr_w(bstrName), grfdex);
763 return E_NOTIMPL;
764}
765
767{
769 FIXME("(%p)->(%x)\n", This, id);
770 return E_NOTIMPL;
771}
772
774{
776 FIXME("(%p)->(%x %x %p)\n", This, id, grfdexFetch, pgrfdex);
777 return E_NOTIMPL;
778}
779
781{
783 FIXME("(%p)->(%x %p)\n", This, id, pbstrName);
784 return E_NOTIMPL;
785}
786
788{
790 FIXME("(%p)->(%x %x %p)\n", This, grfdex, id, pid);
791 return E_NOTIMPL;
792}
793
795{
797 FIXME("(%p)->(%p)\n", This, ppunk);
798 return E_NOTIMPL;
799}
800
801static IDispatchExVtbl ScriptDispVtbl = {
817};
818
820{
822
823 script_disp = heap_alloc_zero(sizeof(*script_disp));
824 if(!script_disp)
825 return E_OUTOFMEMORY;
826
827 script_disp->IDispatchEx_iface.lpVtbl = &ScriptDispVtbl;
828 script_disp->ref = 1;
829 script_disp->ctx = ctx;
830
831 *ret = script_disp;
832 return S_OK;
833}
834
836{
837 vbdisp_t *iter, *iter2;
838
839 LIST_FOR_EACH_ENTRY_SAFE(iter, iter2, &ctx->objects, vbdisp_t, entry)
840 run_terminator(iter);
841
842 while(!list_empty(&ctx->objects)) {
843 iter = LIST_ENTRY(list_head(&ctx->objects), vbdisp_t, entry);
844
845 IDispatchEx_AddRef(&iter->IDispatchEx_iface);
846 clean_props(iter);
847 iter->desc = NULL;
848 list_remove(&iter->entry);
849 list_init(&iter->entry);
850 IDispatchEx_Release(&iter->IDispatchEx_iface);
851 }
852}
853
854HRESULT disp_get_id(IDispatch *disp, BSTR name, vbdisp_invoke_type_t invoke_type, BOOL search_private, DISPID *id)
855{
856 IDispatchEx *dispex;
857 vbdisp_t *vbdisp;
859
860 vbdisp = unsafe_impl_from_IDispatch(disp);
861 if(vbdisp)
862 return vbdisp_get_id(vbdisp, name, invoke_type, search_private, id);
863
864 hres = IDispatch_QueryInterface(disp, &IID_IDispatchEx, (void**)&dispex);
865 if(FAILED(hres)) {
866 TRACE("using IDispatch\n");
867 return IDispatch_GetIDsOfNames(disp, &IID_NULL, &name, 1, 0, id);
868 }
869
870 hres = IDispatchEx_GetDispID(dispex, name, fdexNameCaseInsensitive, id);
871 IDispatchEx_Release(dispex);
872 return hres;
873}
874
875#define RPC_E_SERVER_UNAVAILABLE 0x800706ba
876
878{
880 return hres;
881
882 switch(hres) {
933 }
934
935 return hres;
936}
937
938HRESULT disp_call(script_ctx_t *ctx, IDispatch *disp, DISPID id, DISPPARAMS *dp, VARIANT *retv)
939{
940 const WORD flags = DISPATCH_METHOD|(retv ? DISPATCH_PROPERTYGET : 0);
941 IDispatchEx *dispex;
942 vbdisp_t *vbdisp;
943 EXCEPINFO ei;
945
946 memset(&ei, 0, sizeof(ei));
947 if(retv)
948 V_VT(retv) = VT_EMPTY;
949
950 vbdisp = unsafe_impl_from_IDispatch(disp);
951 if(vbdisp && vbdisp->desc && vbdisp->desc->ctx == ctx)
952 return invoke_vbdisp(vbdisp, id, flags, FALSE, dp, retv);
953
954 hres = IDispatch_QueryInterface(disp, &IID_IDispatchEx, (void**)&dispex);
955 if(FAILED(hres)) {
956 UINT err = 0;
957
958 TRACE("using IDispatch\n");
959 return IDispatch_Invoke(disp, id, &IID_NULL, ctx->lcid, flags, dp, retv, &ei, &err);
960 }
961
962 hres = IDispatchEx_InvokeEx(dispex, id, ctx->lcid, flags, dp, retv, &ei, NULL /* CALLER_FIXME */);
963 IDispatchEx_Release(dispex);
964 return hres;
965}
966
968{
969 DISPPARAMS dp = {NULL};
970 if(!disp)
972 return disp_call(ctx, disp, DISPID_VALUE, &dp, v);
973}
974
976{
977 IDispatchEx *dispex;
978 vbdisp_t *vbdisp;
979 EXCEPINFO ei = {0};
981
982 vbdisp = unsafe_impl_from_IDispatch(disp);
983 if(vbdisp && vbdisp->desc && vbdisp->desc->ctx == ctx)
984 return invoke_vbdisp(vbdisp, id, flags, FALSE, dp, NULL);
985
986 hres = IDispatch_QueryInterface(disp, &IID_IDispatchEx, (void**)&dispex);
987 if(SUCCEEDED(hres)) {
988 hres = IDispatchEx_InvokeEx(dispex, id, ctx->lcid, flags, dp, NULL, &ei, NULL /* FIXME! */);
989 IDispatchEx_Release(dispex);
990 }else {
991 ULONG err = 0;
992
993 TRACE("using IDispatch\n");
994 hres = IDispatch_Invoke(disp, id, &IID_NULL, ctx->lcid, flags, dp, NULL, &ei, &err);
995 }
996
997 return hres;
998}
static void * heap_alloc(size_t len)
Definition: appwiz.h:66
static BOOL heap_free(void *mem)
Definition: appwiz.h:76
static void * heap_realloc(void *mem, size_t len)
Definition: appwiz.h:71
#define InterlockedIncrement
Definition: armddk.h:53
#define InterlockedDecrement
Definition: armddk.h:52
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
Definition: precomp.h:23
static void list_remove(struct list_entry *entry)
Definition: list.h:90
static int list_empty(struct list_entry *head)
Definition: list.h:58
static void list_add_tail(struct list_entry *head, struct list_entry *entry)
Definition: list.h:83
static void list_init(struct list_entry *head)
Definition: list.h:51
#define FIXME(fmt,...)
Definition: precomp.h:53
#define WARN(fmt,...)
Definition: precomp.h:61
const GUID IID_IUnknown
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
#define E_INVALIDARG
Definition: ddrawi.h:101
#define E_NOTIMPL
Definition: ddrawi.h:99
#define NULL
Definition: types.h:112
#define TRUE
Definition: types.h:120
#define FALSE
Definition: types.h:117
OLECHAR * BSTR
Definition: compat.h:2293
@ VT_BYREF
Definition: compat.h:2342
@ VT_ARRAY
Definition: compat.h:2341
@ VT_VARIANT
Definition: compat.h:2307
@ VT_EMPTY
Definition: compat.h:2295
@ VT_DISPATCH
Definition: compat.h:2304
#define wcsicmp
Definition: compat.h:15
HRESULT WINAPI SafeArrayDestroy(SAFEARRAY *psa)
Definition: safearray.c:1347
SAFEARRAY *WINAPI SafeArrayCreate(VARTYPE vt, UINT cDims, SAFEARRAYBOUND *rgsabound)
Definition: safearray.c:600
#define VBSE_PATH_NOT_FOUND
#define VBSE_INVALID_DLL_FUNCTION_NAME
#define VBSE_OBJECT_VARIABLE_NOT_SET
#define VBSE_ILLEGAL_FUNC_CALL
#define VBSE_ARRAY_LOCKED
#define VBSE_PATH_FILE_ACCESS
#define VBSE_OVERFLOW
#define VBSE_NOT_ENUM
#define VBSE_INVALID_TYPELIB_VARIABLE
#define VBSE_OLE_NO_PROP_OR_METHOD
#define VBSE_FUNC_ARITY_MISMATCH
#define VBSE_LOCALE_SETTING_NOT_SUPPORTED
#define VBSE_OLE_FILE_NOT_FOUND
#define VBSE_ACTION_NOT_SUPPORTED
#define VBSE_OUT_OF_BOUNDS
#define VBSE_FILE_NOT_FOUND
#define VBSE_PARAMETER_NOT_OPTIONAL
#define VBSE_CANT_CREATE_TMP_FILE
#define VBSE_OUT_OF_MEMORY
#define VBSE_TOO_MANY_FILES
#define VBSE_TYPE_MISMATCH
#define VBSE_OLE_NOT_SUPPORTED
#define VBSE_NAMED_ARGS_NOT_SUPPORTED
#define VBSE_NAMED_PARAM_NOT_FOUND
#define VBSE_DISK_FULL
#define VBSE_FILE_ALREADY_EXISTS
#define VBSE_CANT_CREATE_OBJECT
#define VBSE_SERVER_NOT_FOUND
#define VBSE_PERMISSION_DENIED
#define VBSE_IO_ERROR
#define assert(x)
Definition: debug.h:53
unsigned int BOOL
Definition: ntddk_ex.h:94
unsigned long DWORD
Definition: ntddk_ex.h:95
unsigned short WORD
Definition: ntddk_ex.h:93
const GLdouble * v
Definition: gl.h:2040
GLenum func
Definition: glext.h:6028
GLuint res
Definition: glext.h:9613
GLenum const GLfloat * params
Definition: glext.h:5645
GLbitfield flags
Definition: glext.h:7161
GLuint id
Definition: glext.h:5910
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint GLint GLint j
Definition: glfuncs.h:250
HRESULT exec_script(HTMLInnerWindow *, const WCHAR *, const WCHAR *, VARIANT *) DECLSPEC_HIDDEN
Definition: script.c:1245
REFIID riid
Definition: atlbase.h:39
REFIID LPVOID * ppv
Definition: atlbase.h:39
#define S_OK
Definition: intsafe.h:52
#define SUCCEEDED(hr)
Definition: intsafe.h:50
#define FAILED(hr)
Definition: intsafe.h:51
uint32_t entry
Definition: isohybrid.c:63
#define debugstr_guid
Definition: kernel32.h:35
#define debugstr_w
Definition: kernel32.h:32
static const WCHAR desc[]
Definition: protectdata.c:36
const char * var
Definition: shader.c:5666
static const char * debugstr_variant(const VARIANT *var)
Definition: container.c:46
HRESULT hres
Definition: protocol.c:465
static IDispatch * script_disp
Definition: run.c:178
static LPOLESTR
Definition: stg_prop.c:27
static VARIANTARG static DISPID
Definition: ordinal.c:52
HRESULT map_hres
Definition: sec_mgr.c:1753
unsigned int UINT
Definition: ndis.h:50
#define V_ARRAYREF(A)
Definition: oleauto.h:223
#define DISPATCH_PROPERTYPUT
Definition: oleauto.h:1008
#define DISPATCH_METHOD
Definition: oleauto.h:1006
#define V_VARIANTREF(A)
Definition: oleauto.h:283
#define V_VT(A)
Definition: oleauto.h:211
#define V_DISPATCH(A)
Definition: oleauto.h:239
#define DISPATCH_PROPERTYGET
Definition: oleauto.h:1007
#define DISPATCH_PROPERTYPUTREF
Definition: oleauto.h:1009
const GUID IID_IDispatch
long LONG
Definition: pedump.c:60
#define IsEqualGUID(rguid1, rguid2)
Definition: guiddef.h:147
#define REFIID
Definition: guiddef.h:118
#define IID_NULL
Definition: guiddef.h:98
#define err(...)
DWORD LCID
Definition: nls.h:13
#define LIST_FOR_EACH_ENTRY_SAFE(cursor, cursor2, list, type, field)
Definition: list.h:204
#define memset(x, y, z)
Definition: compat.h:39
#define TRACE(s)
Definition: solgame.cpp:4
script_ctx_t * ctx
Definition: vbscript.h:98
union _ident_map_t::@592 u
const WCHAR * name
Definition: vbdisp.c:530
function_t * func
Definition: vbdisp.c:534
dynamic_var_t * var
Definition: vbdisp.c:533
BOOL is_var
Definition: vbdisp.c:531
SAFEARRAY ** arrays
Definition: vbscript.h:124
IDispatchEx IDispatchEx_iface
Definition: vbscript.h:117
struct list entry
Definition: vbscript.h:121
const class_desc_t * desc
Definition: vbscript.h:123
LONG ref
Definition: vbscript.h:119
VARIANT props[1]
Definition: vbscript.h:125
Definition: list.h:15
Definition: name.c:39
Definition: send.c:48
#define LIST_ENTRY(type)
Definition: queue.h:175
#define FIELD_OFFSET(t, f)
Definition: typedefs.h:255
#define CONTAINING_RECORD(address, type, field)
Definition: typedefs.h:260
uint32_t ULONG
Definition: typedefs.h:59
HRESULT WINAPI DECLSPEC_HOTPATCH VariantClear(VARIANTARG *pVarg)
Definition: variant.c:648
HRESULT WINAPI VariantCopyInd(VARIANT *pvargDest, VARIANTARG *pvargSrc)
Definition: variant.c:847
static HRESULT WINAPI ScriptDisp_DeleteMemberByDispID(IDispatchEx *iface, DISPID id)
Definition: vbdisp.c:766
static ULONG WINAPI ScriptDisp_AddRef(IDispatchEx *iface)
Definition: vbdisp.c:600
static DISPID ident_to_id(ScriptDisp *This, ident_map_t *ident)
Definition: vbdisp.c:538
static ULONG WINAPI ScriptDisp_Release(IDispatchEx *iface)
Definition: vbdisp.c:610
static vbdisp_t * unsafe_impl_from_IDispatch(IDispatch *iface)
Definition: vbdisp.c:463
static BOOL get_func_id(vbdisp_t *This, const WCHAR *name, vbdisp_invoke_type_t invoke_type, BOOL search_private, DISPID *id)
Definition: vbdisp.c:34
static HRESULT WINAPI ScriptDisp_GetMemberProperties(IDispatchEx *iface, DISPID id, DWORD grfdexFetch, DWORD *pgrfdex)
Definition: vbdisp.c:773
HRESULT create_vbdisp(const class_desc_t *desc, vbdisp_t **ret)
Definition: vbdisp.c:470
HRESULT get_disp_value(script_ctx_t *ctx, IDispatch *disp, VARIANT *v)
Definition: vbdisp.c:967
static BOOL is_func_id(vbdisp_t *This, DISPID id)
Definition: vbdisp.c:29
static HRESULT WINAPI DispatchEx_InvokeEx(IDispatchEx *iface, DISPID id, LCID lcid, WORD wFlags, DISPPARAMS *pdp, VARIANT *pvarRes, EXCEPINFO *pei, IServiceProvider *pspCaller)
Definition: vbdisp.c:387
static HRESULT WINAPI DispatchEx_GetMemberProperties(IDispatchEx *iface, DISPID id, DWORD grfdexFetch, DWORD *pgrfdex)
Definition: vbdisp.c:417
static ULONG WINAPI DispatchEx_Release(IDispatchEx *iface)
Definition: vbdisp.c:309
static HRESULT WINAPI DispatchEx_GetIDsOfNames(IDispatchEx *iface, REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId)
Definition: vbdisp.c:344
static HRESULT WINAPI DispatchEx_DeleteMemberByDispID(IDispatchEx *iface, DISPID id)
Definition: vbdisp.c:410
static HRESULT WINAPI DispatchEx_GetNameSpaceParent(IDispatchEx *iface, IUnknown **ppunk)
Definition: vbdisp.c:438
static HRESULT WINAPI ScriptDisp_QueryInterface(IDispatchEx *iface, REFIID riid, void **ppv)
Definition: vbdisp.c:577
static HRESULT WINAPI DispatchEx_GetDispID(IDispatchEx *iface, BSTR bstrName, DWORD grfdex, DISPID *pid)
Definition: vbdisp.c:366
HRESULT disp_propput(script_ctx_t *ctx, IDispatch *disp, DISPID id, WORD flags, DISPPARAMS *dp)
Definition: vbdisp.c:975
static HRESULT WINAPI ScriptDisp_GetIDsOfNames(IDispatchEx *iface, REFIID riid, LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId)
Definition: vbdisp.c:644
static HRESULT WINAPI DispatchEx_Invoke(IDispatchEx *iface, DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
Definition: vbdisp.c:354
static HRESULT WINAPI DispatchEx_GetMemberName(IDispatchEx *iface, DISPID id, BSTR *pbstrName)
Definition: vbdisp.c:424
HRESULT vbdisp_get_id(vbdisp_t *This, BSTR name, vbdisp_invoke_type_t invoke_type, BOOL search_private, DISPID *id)
Definition: vbdisp.c:59
static void clean_props(vbdisp_t *This)
Definition: vbdisp.c:253
static HRESULT WINAPI ScriptDisp_GetTypeInfoCount(IDispatchEx *iface, UINT *pctinfo)
Definition: vbdisp.c:626
static HRESULT WINAPI ScriptDisp_GetMemberName(IDispatchEx *iface, DISPID id, BSTR *pbstrName)
Definition: vbdisp.c:780
HRESULT disp_get_id(IDispatch *disp, BSTR name, vbdisp_invoke_type_t invoke_type, BOOL search_private, DISPID *id)
Definition: vbdisp.c:854
HRESULT create_script_disp(script_ctx_t *ctx, ScriptDisp **ret)
Definition: vbdisp.c:819
static BOOL run_terminator(vbdisp_t *This)
Definition: vbdisp.c:236
static ident_map_t * id_to_ident(ScriptDisp *This, DISPID id)
Definition: vbdisp.c:543
static HRESULT WINAPI ScriptDisp_GetNextDispID(IDispatchEx *iface, DWORD grfdex, DISPID id, DISPID *pid)
Definition: vbdisp.c:787
static HRESULT WINAPI DispatchEx_GetNextDispID(IDispatchEx *iface, DWORD grfdex, DISPID id, DISPID *pid)
Definition: vbdisp.c:431
static ident_map_t * add_ident(ScriptDisp *This, const WCHAR *name)
Definition: vbdisp.c:548
static ScriptDisp * ScriptDisp_from_IDispatchEx(IDispatchEx *iface)
Definition: vbdisp.c:572
static HRESULT WINAPI DispatchEx_QueryInterface(IDispatchEx *iface, REFIID riid, void **ppv)
Definition: vbdisp.c:276
static HRESULT invoke_variant_prop(script_ctx_t *ctx, VARIANT *v, WORD flags, DISPPARAMS *dp, VARIANT *res)
Definition: vbdisp.c:116
static vbdisp_t * impl_from_IDispatchEx(IDispatchEx *iface)
Definition: vbdisp.c:271
static HRESULT WINAPI ScriptDisp_Invoke(IDispatchEx *iface, DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
Definition: vbdisp.c:663
#define RPC_E_SERVER_UNAVAILABLE
Definition: vbdisp.c:875
static ULONG WINAPI DispatchEx_AddRef(IDispatchEx *iface)
Definition: vbdisp.c:299
static HRESULT WINAPI ScriptDisp_GetNameSpaceParent(IDispatchEx *iface, IUnknown **ppunk)
Definition: vbdisp.c:794
static IDispatchExVtbl ScriptDispVtbl
Definition: vbdisp.c:801
static HRESULT WINAPI ScriptDisp_GetDispID(IDispatchEx *iface, BSTR bstrName, DWORD grfdex, DISPID *pid)
Definition: vbdisp.c:675
static HRESULT get_propput_arg(script_ctx_t *ctx, const DISPPARAMS *dp, WORD flags, VARIANT *v, BOOL *is_owned)
Definition: vbdisp.c:80
static HRESULT WINAPI ScriptDisp_InvokeEx(IDispatchEx *iface, DISPID id, LCID lcid, WORD wFlags, DISPPARAMS *pdp, VARIANT *pvarRes, EXCEPINFO *pei, IServiceProvider *pspCaller)
Definition: vbdisp.c:724
HRESULT disp_call(script_ctx_t *ctx, IDispatch *disp, DISPID id, DISPPARAMS *dp, VARIANT *retv)
Definition: vbdisp.c:938
static HRESULT WINAPI DispatchEx_GetTypeInfo(IDispatchEx *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
Definition: vbdisp.c:336
static HRESULT WINAPI DispatchEx_DeleteMemberByName(IDispatchEx *iface, BSTR bstrName, DWORD grfdex)
Definition: vbdisp.c:403
static HRESULT WINAPI DispatchEx_GetTypeInfoCount(IDispatchEx *iface, UINT *pctinfo)
Definition: vbdisp.c:326
void collect_objects(script_ctx_t *ctx)
Definition: vbdisp.c:835
static HRESULT WINAPI ScriptDisp_DeleteMemberByName(IDispatchEx *iface, BSTR bstrName, DWORD grfdex)
Definition: vbdisp.c:759
static HRESULT WINAPI ScriptDisp_GetTypeInfo(IDispatchEx *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
Definition: vbdisp.c:636
static IDispatchExVtbl DispatchExVtbl
Definition: vbdisp.c:445
static HRESULT invoke_vbdisp(vbdisp_t *This, DISPID id, DWORD flags, BOOL extern_caller, DISPPARAMS *params, VARIANT *res)
Definition: vbdisp.c:164
vbdisp_invoke_type_t
Definition: vbscript.h:71
@ VBDISP_LET
Definition: vbscript.h:73
@ VBDISP_SET
Definition: vbscript.h:74
@ VBDISP_CALLGET
Definition: vbscript.h:72
@ VBDISP_ANY
Definition: vbscript.h:75
#define FACILITY_VBS
Definition: vbscript.h:378
static unsigned arg_cnt(const DISPPARAMS *dp)
Definition: vbscript.h:162
@ FUNC_PROPGET
Definition: vbscript.h:311
@ FUNC_DEFGET
Definition: vbscript.h:314
struct _vbdisp_t vbdisp_t
Definition: vbscript.h:61
#define MAKE_VBSERROR(code)
Definition: vbscript.h:379
static const WCHAR props[]
Definition: wbemdisp.c:288
int ret
_In_ DWORD _Out_ _In_ WORD wFlags
Definition: wincon.h:531
_In_ ULONG _In_ ULONG_PTR ident
Definition: winddi.h:3994
_In_ ULONG_PTR _In_ ULONG _Out_ ULONG_PTR * pid
Definition: winddi.h:3837
#define WINAPI
Definition: msvc.h:6
#define REGDB_E_CLASSNOTREG
Definition: winerror.h:2696
#define STG_E_SHAREVIOLATION
Definition: winerror.h:2577
#define TYPE_E_CANTCREATETMPFILE
Definition: winerror.h:2551
#define DISP_E_PARAMNOTFOUND
Definition: winerror.h:2513
#define DISP_E_NONAMEDARGS
Definition: winerror.h:2516
#define DISP_E_ARRAYISLOCKED
Definition: winerror.h:2522
#define STG_E_INUSE
Definition: winerror.h:2588
#define STG_E_PATHNOTFOUND
Definition: winerror.h:2566
#define MK_E_UNAVAILABLE
Definition: winerror.h:2784
#define STG_E_TOOMANYOPENFILES
Definition: winerror.h:2567
#define TYPE_E_DLLFUNCTIONNOTFOUND
Definition: winerror.h:2543
#define STG_E_NOTCURRENT
Definition: winerror.h:2589
#define STG_E_CANTSAVE
Definition: winerror.h:2591
#define STG_E_LOCKVIOLATION
Definition: winerror.h:2578
#define STG_E_INVALIDNAME
Definition: winerror.h:2584
#define E_NOINTERFACE
Definition: winerror.h:2364
#define HRESULT_FACILITY(hr)
Definition: winerror.h:79
#define DISP_E_UNKNOWNINTERFACE
Definition: winerror.h:2511
#define DISP_E_OVERFLOW
Definition: winerror.h:2519
#define STG_E_READFAULT
Definition: winerror.h:2576
#define DISP_E_BADVARTYPE
Definition: winerror.h:2517
#define DISP_E_BADPARAMCOUNT
Definition: winerror.h:2523
#define STG_E_DISKISWRITEPROTECTED
Definition: winerror.h:2573
#define STG_E_FILEALREADYEXISTS
Definition: winerror.h:2579
#define CO_E_APPDIDNTREG
Definition: winerror.h:2817
#define E_ACCESSDENIED
Definition: winerror.h:2849
#define TYPE_E_TYPEMISMATCH
Definition: winerror.h:2548
#define STG_E_FILENOTFOUND
Definition: winerror.h:2565
#define DISP_E_NOTACOLLECTION
Definition: winerror.h:2526
#define DISP_E_MEMBERNOTFOUND
Definition: winerror.h:2512
#define STG_E_ACCESSDENIED
Definition: winerror.h:2568
#define CO_E_APPNOTFOUND
Definition: winerror.h:2808
#define MK_E_CANTOPENFILE
Definition: winerror.h:2791
#define E_UNEXPECTED
Definition: winerror.h:2456
#define DISP_E_EXCEPTION
Definition: winerror.h:2518
#define DISP_E_BADINDEX
Definition: winerror.h:2520
#define DISP_E_UNKNOWNLCID
Definition: winerror.h:2521
#define TYPE_E_IOERROR
Definition: winerror.h:2550
#define STG_E_MEDIUMFULL
Definition: winerror.h:2581
#define CO_E_SERVER_EXEC_FAILURE
Definition: winerror.h:2860
#define STG_E_WRITEFAULT
Definition: winerror.h:2575
#define MK_E_INVALIDEXTENSION
Definition: winerror.h:2787
#define DISP_E_TYPEMISMATCH
Definition: winerror.h:2514
#define STG_E_NOMOREFILES
Definition: winerror.h:2572
#define DISP_E_PARAMNOTOPTIONAL
Definition: winerror.h:2524
#define TYPE_E_OUTOFBOUNDS
Definition: winerror.h:2549
#define DISP_E_UNKNOWNNAME
Definition: winerror.h:2515
#define STG_E_INSUFFICIENTMEMORY
Definition: winerror.h:2570
#define CO_E_CLASSSTRING
Definition: winerror.h:2806
__wchar_t WCHAR
Definition: xmlstorage.h:180