ReactOS 0.4.16-dev-319-g6cf4263
oleobject.c
Go to the documentation of this file.
1/*
2 * Implementation of IOleObject interfaces for WebBrowser control
3 *
4 * - IOleObject
5 * - IOleInPlaceObject
6 * - IOleControl
7 *
8 * Copyright 2001 John R. Sheets (for CodeWeavers)
9 * Copyright 2005 Jacek Caban
10 *
11 * This library is free software; you can redistribute it and/or
12 * modify it under the terms of the GNU Lesser General Public
13 * License as published by the Free Software Foundation; either
14 * version 2.1 of the License, or (at your option) any later version.
15 *
16 * This library is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 * Lesser General Public License for more details.
20 *
21 * You should have received a copy of the GNU Lesser General Public
22 * License along with this library; if not, write to the Free Software
23 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
24 */
25
26#include <string.h>
27
28#include "ieframe.h"
29
30#include "htiframe.h"
31#include "idispids.h"
32#include "mshtmdid.h"
33
34#include "wine/debug.h"
35
37
38/* shlwapi.dll */
40
42
44{
45 if(This->doc_host.hwnd)
46 SetWindowPos(This->doc_host.hwnd, NULL, 0, 0, width, height,
48
49 return 0;
50}
51
52static void notify_on_focus(WebBrowser *This, BOOL got_focus)
53{
54 IOleControlSite *control_site;
56
57 if(!This->client)
58 return;
59
60 hres = IOleClientSite_QueryInterface(This->client, &IID_IOleControlSite, (void**)&control_site);
61 if(FAILED(hres))
62 return;
63
64 IOleControlSite_OnFocus(control_site, got_focus);
65 IOleControlSite_Release(control_site);
66}
67
69{
71
72 static const WCHAR wszTHIS[] = {'T','H','I','S',0};
73
74 if(msg == WM_CREATE) {
76 SetPropW(hwnd, wszTHIS, This);
77 }else {
78 This = GetPropW(hwnd, wszTHIS);
79 }
80
81 switch(msg) {
82 case WM_SIZE:
84 case WM_DOCHOSTTASK:
85 return process_dochost_tasks(&This->doc_host);
86 case WM_SETFOCUS:
88 break;
89 case WM_KILLFOCUS:
91 break;
92 }
93
95}
96
98{
99 IOleInPlaceSite *inplace;
100 HWND parent = NULL;
102
103 static const WCHAR wszShellEmbedding[] =
104 {'S','h','e','l','l',' ','E','m','b','e','d','d','i','n','g',0};
105
107 static WNDCLASSEXW wndclass = {
108 sizeof(wndclass),
111 0, 0 /* native uses 8 */, NULL, NULL, NULL,
112 (HBRUSH)(COLOR_WINDOW + 1), NULL,
113 wszShellEmbedding,
114 NULL
115 };
116 wndclass.hInstance = ieframe_instance;
117
118 RegisterClassExW(&wndclass);
119 }
120
121 hres = IOleClientSite_QueryInterface(This->client, &IID_IOleInPlaceSite, (void**)&inplace);
122 if(SUCCEEDED(hres)) {
123 IOleInPlaceSite_GetWindow(inplace, &parent);
124 IOleInPlaceSite_Release(inplace);
125 }
126
127 This->doc_host.frame_hwnd = This->shell_embedding_hwnd = CreateWindowExW(
129 wszShellEmbedding, wszShellEmbedding,
132 0, 0, 0, 0, parent,
134
135 TRACE("parent=%p hwnd=%p\n", parent, This->shell_embedding_hwnd);
136}
137
139{
140 HWND parent_hwnd;
142
143 if(This->inplace)
144 return S_OK;
145
146 if(!active_site)
147 return E_INVALIDARG;
148
149 hres = IOleClientSite_QueryInterface(active_site, &IID_IOleInPlaceSite,
150 (void**)&This->inplace);
151 if(FAILED(hres)) {
152 WARN("Could not get IOleInPlaceSite\n");
153 return hres;
154 }
155
156 hres = IOleInPlaceSiteEx_CanInPlaceActivate(This->inplace);
157 if(hres != S_OK) {
158 WARN("CanInPlaceActivate returned: %08x\n", hres);
159 IOleInPlaceSiteEx_Release(This->inplace);
160 This->inplace = NULL;
161 return E_FAIL;
162 }
163
164 hres = IOleInPlaceSiteEx_GetWindow(This->inplace, &parent_hwnd);
165 if(SUCCEEDED(hres))
166 SHSetParentHwnd(This->shell_embedding_hwnd, parent_hwnd);
167
168 IOleInPlaceSiteEx_OnInPlaceActivate(This->inplace);
169
170 This->frameinfo.cb = sizeof(OLEINPLACEFRAMEINFO);
171 IOleInPlaceSiteEx_GetWindowContext(This->inplace, &This->doc_host.frame, &This->uiwindow,
172 &This->pos_rect, &This->clip_rect,
173 &This->frameinfo);
174
175 SetWindowPos(This->shell_embedding_hwnd, NULL,
176 This->pos_rect.left, This->pos_rect.top,
177 This->pos_rect.right-This->pos_rect.left,
178 This->pos_rect.bottom-This->pos_rect.top,
180
181 if(This->client) {
183
184 IOleClientSite_ShowObject(This->client);
185
186 hres = IOleClientSite_GetContainer(This->client, &container);
187 if(SUCCEEDED(hres)) {
188 if(This->container)
189 IOleContainer_Release(This->container);
190 This->container = container;
191 }
192 }
193
194 if(This->doc_host.frame)
195 IOleInPlaceFrame_GetWindow(This->doc_host.frame, &This->frame_hwnd);
196
197 return S_OK;
198}
199
201{
203
204 static const WCHAR wszitem[] = {'i','t','e','m',0};
205
206 if(This->inplace)
207 {
208 if(This->shell_embedding_hwnd)
209 ShowWindow(This->shell_embedding_hwnd, SW_SHOW);
210 return S_OK;
211 }
212
213 hres = activate_inplace(This, active_site);
214 if(FAILED(hres))
215 return hres;
216
217 IOleInPlaceSiteEx_OnUIActivate(This->inplace);
218
219 if(This->doc_host.frame)
220 IOleInPlaceFrame_SetActiveObject(This->doc_host.frame, &This->IOleInPlaceActiveObject_iface, wszitem);
221 if(This->uiwindow)
222 IOleInPlaceUIWindow_SetActiveObject(This->uiwindow, &This->IOleInPlaceActiveObject_iface, wszitem);
223
224 if(This->doc_host.frame)
225 IOleInPlaceFrame_SetMenu(This->doc_host.frame, NULL, NULL, This->shell_embedding_hwnd);
226
227 SetFocus(This->shell_embedding_hwnd);
229
230 return S_OK;
231}
232
234{
235 IDispatch *disp = NULL;
236 DISPPARAMS dispparams = {NULL, 0};
238
240
241 if(!client)
242 return S_OK;
243
244 hres = IOleClientSite_QueryInterface(client, &IID_IDispatch, (void**)&disp);
245 if(FAILED(hres)) {
246 TRACE("Could not get IDispatch\n");
247 return hres;
248 }
249
250 hres = IDispatch_Invoke(disp, dispid, &IID_NULL, LOCALE_SYSTEM_DEFAULT,
251 DISPATCH_PROPERTYGET, &dispparams, res, NULL, NULL);
252
253 IDispatch_Release(disp);
254
255 return hres;
256}
257
259{
260 VARIANT offline;
261
263
264 if(V_VT(&offline) == VT_BOOL)
265 IWebBrowser2_put_Offline(&This->IWebBrowser2_iface, V_BOOL(&offline));
266 else if(V_VT(&offline) != VT_EMPTY)
267 WARN("wrong V_VT(silent) %d\n", V_VT(&offline));
268
269 return S_OK;
270}
271
273{
275
277
278 if(V_VT(&silent) == VT_BOOL)
279 IWebBrowser2_put_Silent(&This->IWebBrowser2_iface, V_BOOL(&silent));
280 else if(V_VT(&silent) != VT_EMPTY)
281 WARN("wrong V_VT(silent) %d\n", V_VT(&silent));
282
283 return S_OK;
284}
285
286static void release_client_site(WebBrowser *This, BOOL destroy_win)
287{
288 release_dochost_client(&This->doc_host);
289
290 if(This->client) {
291 IOleClientSite_Release(This->client);
292 This->client = NULL;
293 }
294
295 if(This->client_closed) {
296 IOleClientSite_Release(This->client_closed);
297 This->client_closed = NULL;
298 }
299
300 if(destroy_win && This->shell_embedding_hwnd) {
301 DestroyWindow(This->shell_embedding_hwnd);
302 This->shell_embedding_hwnd = NULL;
303 }
304
305 if(This->inplace) {
306 IOleInPlaceSiteEx_Release(This->inplace);
307 This->inplace = NULL;
308 }
309
310 if(This->container) {
311 IOleContainer_Release(This->container);
312 This->container = NULL;
313 }
314
315 if(This->uiwindow) {
316 IOleInPlaceUIWindow_Release(This->uiwindow);
317 This->uiwindow = NULL;
318 }
319}
320
321typedef struct {
326
328{
329 return CONTAINING_RECORD(iface, EnumOLEVERB, IEnumOLEVERB_iface);
330}
331
333{
335
337 TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv);
338 *ppv = &This->IEnumOLEVERB_iface;
339 }else if(IsEqualGUID(&IID_IEnumOLEVERB, riid)) {
340 TRACE("(%p)->(IID_IEnumOLEVERB %p)\n", This, ppv);
341 *ppv = &This->IEnumOLEVERB_iface;
342 }else {
343 WARN("(%p)->(%s %p)\n", This, debugstr_guid(riid), ppv);
344 *ppv = NULL;
345 return E_NOINTERFACE;
346 }
347
348 IUnknown_AddRef((IUnknown*)*ppv);
349 return S_OK;
350}
351
353{
356
357 TRACE("(%p) ref=%d\n", This, ref);
358
359 return ref;
360}
361
363{
366
367 TRACE("(%p) ref=%d\n", This, ref);
368
369 if(!ref)
371
372 return ref;
373}
374
375static HRESULT WINAPI EnumOLEVERB_Next(IEnumOLEVERB *iface, ULONG celt, OLEVERB *rgelt, ULONG *pceltFetched)
376{
378
379 static const OLEVERB verbs[] =
381
382 TRACE("(%p)->(%u %p %p)\n", This, celt, rgelt, pceltFetched);
383
384 /* There are a few problems with this implementation, but that's how it seems to work in native. See tests. */
385 if(pceltFetched)
386 *pceltFetched = 0;
387
388 if(This->iter == ARRAY_SIZE(verbs))
389 return S_FALSE;
390
391 if(celt)
392 *rgelt = verbs[This->iter++];
393 return S_OK;
394}
395
397{
399 TRACE("(%p)->(%u)\n", This, celt);
400 return S_OK;
401}
402
404{
406
407 TRACE("(%p)\n", This);
408
409 This->iter = 0;
410 return S_OK;
411}
412
414{
416 FIXME("(%p)->(%p)\n", This, ppenum);
417 return E_NOTIMPL;
418}
419
420static const IEnumOLEVERBVtbl EnumOLEVERBVtbl = {
428};
429
430/**********************************************************************
431 * Implement the IOleObject interface for the WebBrowser control
432 */
433
435{
436 return CONTAINING_RECORD(iface, WebBrowser, IOleObject_iface);
437}
438
440{
442 return IWebBrowser2_QueryInterface(&This->IWebBrowser2_iface, riid, ppv);
443}
444
446{
448 return IWebBrowser2_AddRef(&This->IWebBrowser2_iface);
449}
450
452{
454 return IWebBrowser2_Release(&This->IWebBrowser2_iface);
455}
456
457static HRESULT WINAPI OleObject_SetClientSite(IOleObject *iface, LPOLECLIENTSITE pClientSite)
458{
460 IDocHostUIHandler *hostui;
461 IOleCommandTarget *olecmd;
462 BOOL get_olecmd = TRUE;
464 IDispatch *disp;
466
467 TRACE("(%p)->(%p)\n", This, pClientSite);
468
469 if(This->client_closed) {
470 IOleClientSite_Release(This->client_closed);
471 This->client_closed = NULL;
472 }
473
474 if(This->client == pClientSite)
475 return S_OK;
476
477 if(This->client && pClientSite) {
478 get_olecmd = FALSE;
479 olecmd = This->doc_host.olecmd;
480 if(olecmd)
481 IOleCommandTarget_AddRef(olecmd);
482 }
483
484 release_client_site(This, !pClientSite);
485
486 if(!pClientSite) {
487 on_commandstate_change(&This->doc_host, CSC_NAVIGATEBACK, FALSE);
488 on_commandstate_change(&This->doc_host, CSC_NAVIGATEFORWARD, FALSE);
489
490 if(This->doc_host.document)
491 deactivate_document(&This->doc_host);
492 return S_OK;
493 }
494
495 IOleClientSite_AddRef(pClientSite);
496 This->client = pClientSite;
497
498 hres = IOleClientSite_QueryInterface(This->client, &IID_IDispatch,
499 (void**)&disp);
500 if(SUCCEEDED(hres))
501 This->doc_host.client_disp = disp;
502
503 hres = IOleClientSite_QueryInterface(This->client, &IID_IDocHostUIHandler,
504 (void**)&hostui);
505 if(SUCCEEDED(hres))
506 This->doc_host.hostui = hostui;
507
508 if(get_olecmd) {
509 hres = IOleClientSite_GetContainer(This->client, &container);
510 if(SUCCEEDED(hres)) {
511 ITargetContainer *target_container;
512
513 hres = IOleContainer_QueryInterface(container, &IID_ITargetContainer,
514 (void**)&target_container);
515 if(SUCCEEDED(hres)) {
516 FIXME("Unsupported ITargetContainer\n");
517 ITargetContainer_Release(target_container);
518 }
519
520 hres = IOleContainer_QueryInterface(container, &IID_IOleCommandTarget, (void**)&olecmd);
521 if(FAILED(hres))
522 olecmd = NULL;
523
524 IOleContainer_Release(container);
525 }else {
526 hres = IOleClientSite_QueryInterface(This->client, &IID_IOleCommandTarget, (void**)&olecmd);
527 if(FAILED(hres))
528 olecmd = NULL;
529 }
530 }
531
532 This->doc_host.olecmd = olecmd;
533
534 if(This->shell_embedding_hwnd) {
535 IOleInPlaceSite *inplace;
536 HWND parent;
537
538 hres = IOleClientSite_QueryInterface(This->client, &IID_IOleInPlaceSite, (void**)&inplace);
539 if(SUCCEEDED(hres)) {
540 hres = IOleInPlaceSite_GetWindow(inplace, &parent);
541 IOleInPlaceSite_Release(inplace);
542 if(SUCCEEDED(hres))
543 SHSetParentHwnd(This->shell_embedding_hwnd, parent);
544 }
545 }else {
547 }
548
551
552 return S_OK;
553}
554
555static HRESULT WINAPI OleObject_GetClientSite(IOleObject *iface, LPOLECLIENTSITE *ppClientSite)
556{
558
559 TRACE("(%p)->(%p)\n", This, ppClientSite);
560
561 if(!ppClientSite)
562 return E_INVALIDARG;
563
564 if(This->client)
565 IOleClientSite_AddRef(This->client);
566 *ppClientSite = This->client;
567
568 return S_OK;
569}
570
571static HRESULT WINAPI OleObject_SetHostNames(IOleObject *iface, LPCOLESTR szContainerApp,
572 LPCOLESTR szContainerObj)
573{
575
576 TRACE("(%p)->(%s, %s)\n", This, debugstr_w(szContainerApp), debugstr_w(szContainerObj));
577
578 /* We have nothing to do here. */
579 return S_OK;
580}
581
582static HRESULT WINAPI OleObject_Close(IOleObject *iface, DWORD dwSaveOption)
583{
587
588 TRACE("(%p)->(%d)\n", This, dwSaveOption);
589
590 if(dwSaveOption != OLECLOSE_NOSAVE) {
591 FIXME("unimplemented flag: %x\n", dwSaveOption);
592 return E_NOTIMPL;
593 }
594
595 if(This->doc_host.frame)
596 IOleInPlaceFrame_SetActiveObject(This->doc_host.frame, NULL, NULL);
597
598 if(This->uiwindow)
599 IOleInPlaceUIWindow_SetActiveObject(This->uiwindow, NULL, NULL);
600
601 if(This->inplace)
602 IOleInPlaceSiteEx_OnUIDeactivate(This->inplace, FALSE);
604 if(This->inplace)
605 IOleInPlaceSiteEx_OnInPlaceDeactivate(This->inplace);
606
607 /* store old client site - we need to restore it in DoVerb */
608 client = This->client;
609 if(This->client)
610 IOleClientSite_AddRef(This->client);
611 hres = IOleObject_SetClientSite(iface, NULL);
612 This->client_closed = client;
613 return hres;
614}
615
616static HRESULT WINAPI OleObject_SetMoniker(IOleObject *iface, DWORD dwWhichMoniker, IMoniker* pmk)
617{
619 FIXME("(%p)->(%d, %p)\n", This, dwWhichMoniker, pmk);
620 return E_NOTIMPL;
621}
622
624 DWORD dwWhichMoniker, LPMONIKER *ppmk)
625{
627 FIXME("(%p)->(%d, %d, %p)\n", This, dwAssign, dwWhichMoniker, ppmk);
628 return E_NOTIMPL;
629}
630
632 BOOL fCreation, DWORD dwReserved)
633{
635 FIXME("(%p)->(%p, %d, %d)\n", This, pDataObject, fCreation, dwReserved);
636 return E_NOTIMPL;
637}
638
640 LPDATAOBJECT *ppDataObject)
641{
643 FIXME("(%p)->(%d, %p)\n", This, dwReserved, ppDataObject);
644 return E_NOTIMPL;
645}
646
647static HRESULT WINAPI OleObject_DoVerb(IOleObject *iface, LONG iVerb, struct tagMSG* lpmsg,
648 LPOLECLIENTSITE pActiveSite, LONG lindex, HWND hwndParent, LPCRECT lprcPosRect)
649{
651
652 TRACE("(%p)->(%d %p %p %d %p %s)\n", This, iVerb, lpmsg, pActiveSite, lindex, hwndParent,
653 wine_dbgstr_rect(lprcPosRect));
654
655 /* restore closed client site if we have one */
656 if(!This->client && This->client_closed) {
657 IOleClientSite *client = This->client_closed;
658 This->client_closed = NULL;
659 IOleObject_SetClientSite(iface, client);
660 IOleClientSite_Release(client);
661 }
662
663 switch (iVerb)
664 {
665 case OLEIVERB_SHOW:
666 TRACE("OLEIVERB_SHOW\n");
667 return activate_ui(This, pActiveSite);
669 TRACE("OLEIVERB_UIACTIVATE\n");
670 return activate_ui(This, pActiveSite);
672 TRACE("OLEIVERB_INPLACEACTIVATE\n");
673 return activate_inplace(This, pActiveSite);
674 case OLEIVERB_HIDE:
675 TRACE("OLEIVERB_HIDE\n");
676 if(This->inplace)
677 IOleInPlaceSiteEx_OnInPlaceDeactivate(This->inplace);
678 if(This->shell_embedding_hwnd)
679 ShowWindow(This->shell_embedding_hwnd, SW_HIDE);
680 return S_OK;
681 default:
682 FIXME("stub for %d\n", iVerb);
683 break;
684 }
685
686 return E_NOTIMPL;
687}
688
690{
693
694 TRACE("(%p)->(%p)\n", This, ppEnumOleVerb);
695
696 ret = heap_alloc(sizeof(*ret));
697 if(!ret)
698 return E_OUTOFMEMORY;
699
700 ret->IEnumOLEVERB_iface.lpVtbl = &EnumOLEVERBVtbl;
701 ret->ref = 1;
702 ret->iter = 0;
703
704 *ppEnumOleVerb = &ret->IEnumOLEVERB_iface;
705 return S_OK;
706}
707
709{
711 FIXME("(%p)\n", This);
712 return E_NOTIMPL;
713}
714
716{
718 FIXME("(%p)\n", This);
719 return E_NOTIMPL;
720}
721
723{
725 FIXME("(%p)->(%p)\n", This, pClsid);
726 return E_NOTIMPL;
727}
728
730 LPOLESTR* pszUserType)
731{
733 TRACE("(%p, %d, %p)\n", This, dwFormOfType, pszUserType);
734 return OleRegGetUserType(&CLSID_WebBrowser, dwFormOfType, pszUserType);
735}
736
737static HRESULT WINAPI OleObject_SetExtent(IOleObject *iface, DWORD dwDrawAspect, SIZEL *psizel)
738{
740
741 TRACE("(%p)->(%x %p)\n", This, dwDrawAspect, psizel);
742
743 /* Tests show that dwDrawAspect is ignored */
744 This->extent = *psizel;
745 return S_OK;
746}
747
748static HRESULT WINAPI OleObject_GetExtent(IOleObject *iface, DWORD dwDrawAspect, SIZEL *psizel)
749{
751
752 TRACE("(%p)->(%x, %p)\n", This, dwDrawAspect, psizel);
753
754 /* Tests show that dwDrawAspect is ignored */
755 *psizel = This->extent;
756 return S_OK;
757}
758
760 DWORD* pdwConnection)
761{
763 FIXME("(%p)->(%p, %p)\n", This, pAdvSink, pdwConnection);
764 return E_NOTIMPL;
765}
766
768{
770 FIXME("(%p)->(%d)\n", This, dwConnection);
771 return E_NOTIMPL;
772}
773
775{
777 FIXME("(%p)->(%p)\n", This, ppenumAdvise);
778 return S_OK;
779}
780
781static HRESULT WINAPI OleObject_GetMiscStatus(IOleObject *iface, DWORD dwAspect, DWORD *pdwStatus)
782{
784
785 TRACE("(%p)->(%x, %p)\n", This, dwAspect, pdwStatus);
786
789
790 return S_OK;
791}
792
794{
796 FIXME("(%p)->(%p)\n", This, pLogpal);
797 return E_NOTIMPL;
798}
799
800static const IOleObjectVtbl OleObjectVtbl =
801{
826};
827
828/**********************************************************************
829 * Implement the IOleInPlaceObject interface
830 */
831
833{
834 return CONTAINING_RECORD(iface, WebBrowser, IOleInPlaceObject_iface);
835}
836
838 REFIID riid, LPVOID *ppobj)
839{
841 return IWebBrowser2_QueryInterface(&This->IWebBrowser2_iface, riid, ppobj);
842}
843
845{
847 return IWebBrowser2_AddRef(&This->IWebBrowser2_iface);
848}
849
851{
853 return IWebBrowser2_Release(&This->IWebBrowser2_iface);
854}
855
857{
859
860 TRACE("(%p)->(%p)\n", This, phwnd);
861
862 *phwnd = This->shell_embedding_hwnd;
863 return S_OK;
864}
865
867 BOOL fEnterMode)
868{
870 FIXME("(%p)->(%x)\n", This, fEnterMode);
871 return E_NOTIMPL;
872}
873
875{
877 FIXME("(%p)\n", This);
878
879 if(This->inplace) {
880 IOleInPlaceSiteEx_Release(This->inplace);
881 This->inplace = NULL;
882 }
883
884 return S_OK;
885}
886
888{
890 FIXME("(%p)\n", This);
891 return E_NOTIMPL;
892}
893
895 LPCRECT lprcPosRect, LPCRECT lprcClipRect)
896{
898
899 TRACE("(%p)->(%s %s)\n", This, wine_dbgstr_rect(lprcPosRect), wine_dbgstr_rect(lprcClipRect));
900
901 This->pos_rect = *lprcPosRect;
902
903 if(lprcClipRect)
904 This->clip_rect = *lprcClipRect;
905
906 if(This->shell_embedding_hwnd) {
907 SetWindowPos(This->shell_embedding_hwnd, NULL,
908 lprcPosRect->left, lprcPosRect->top,
909 lprcPosRect->right-lprcPosRect->left,
910 lprcPosRect->bottom-lprcPosRect->top,
912 }
913
914 return S_OK;
915}
916
918{
920 FIXME("(%p)\n", This);
921 return E_NOTIMPL;
922}
923
924static const IOleInPlaceObjectVtbl OleInPlaceObjectVtbl =
925{
935};
936
937/**********************************************************************
938 * Implement the IOleControl interface
939 */
940
942{
943 return CONTAINING_RECORD(iface, WebBrowser, IOleControl_iface);
944}
945
947 REFIID riid, LPVOID *ppobj)
948{
950 return IWebBrowser2_QueryInterface(&This->IWebBrowser2_iface, riid, ppobj);
951}
952
954{
956 return IWebBrowser2_AddRef(&This->IWebBrowser2_iface);
957}
958
960{
962 return IWebBrowser2_Release(&This->IWebBrowser2_iface);
963}
964
965static HRESULT WINAPI OleControl_GetControlInfo(IOleControl *iface, LPCONTROLINFO pCI)
966{
968
969 TRACE("(%p)->(%p)\n", This, pCI);
970
971 /* Tests show that this function should be not implemented */
972 return E_NOTIMPL;
973}
974
976{
978 FIXME("(%p)->(%p)\n", This, pMsg);
979 return E_NOTIMPL;
980}
981
983{
985
986 TRACE("(%p)->(%d)\n", This, dispID);
987
988 switch(dispID) {
989 case DISPID_UNKNOWN:
990 /* Unknown means multiple properties changed, so check them all.
991 * BUT the Webbrowser OleControl object doesn't appear to do this.
992 */
993 return S_OK;
995 return S_OK;
999 return on_silent_change(This);
1000 }
1001
1002 FIXME("Unknown dispID %d\n", dispID);
1003 return E_NOTIMPL;
1004}
1005
1007{
1009 FIXME("(%p)->(%x)\n", This, bFreeze);
1010 return E_NOTIMPL;
1011}
1012
1013static const IOleControlVtbl OleControlVtbl =
1014{
1022};
1023
1025{
1026 return CONTAINING_RECORD(iface, WebBrowser, IOleInPlaceActiveObject_iface);
1027}
1028
1030 REFIID riid, void **ppv)
1031{
1033 return IWebBrowser2_QueryInterface(&This->IWebBrowser2_iface, riid, ppv);
1034}
1035
1037{
1039 return IWebBrowser2_AddRef(&This->IWebBrowser2_iface);
1040}
1041
1043{
1045 return IWebBrowser2_Release(&This->IWebBrowser2_iface);
1046}
1047
1049 HWND *phwnd)
1050{
1052 return IOleInPlaceObject_GetWindow(&This->IOleInPlaceObject_iface, phwnd);
1053}
1054
1056 BOOL fEnterMode)
1057{
1059 return IOleInPlaceObject_ContextSensitiveHelp(&This->IOleInPlaceObject_iface, fEnterMode);
1060}
1061
1063 LPMSG lpmsg)
1064{
1066 IOleInPlaceActiveObject *activeobj;
1067 HRESULT hr = S_FALSE;
1068
1069 TRACE("(%p)->(%p)\n", This, lpmsg);
1070
1071 if(This->doc_host.document) {
1072 if(SUCCEEDED(IUnknown_QueryInterface(This->doc_host.document,
1074 (void**)&activeobj))) {
1075 hr = IOleInPlaceActiveObject_TranslateAccelerator(activeobj, lpmsg);
1076 IOleInPlaceActiveObject_Release(activeobj);
1077 }
1078 }
1079
1080 if(SUCCEEDED(hr))
1081 return hr;
1082 else
1083 return S_FALSE;
1084}
1085
1087 BOOL fActivate)
1088{
1090 FIXME("(%p)->(%x)\n", This, fActivate);
1091 return E_NOTIMPL;
1092}
1093
1095 BOOL fActivate)
1096{
1098 FIXME("(%p)->(%x)\n", This, fActivate);
1099 return E_NOTIMPL;
1100}
1101
1103 LPCRECT lprcBorder, IOleInPlaceUIWindow *pUIWindow, BOOL fFrameWindow)
1104{
1106 FIXME("(%p)->(%p %p %x)\n", This, lprcBorder, pUIWindow, fFrameWindow);
1107 return E_NOTIMPL;
1108}
1109
1111 BOOL fEnable)
1112{
1114 FIXME("(%p)->(%x)\n", This, fEnable);
1115 return E_NOTIMPL;
1116}
1117
1118static const IOleInPlaceActiveObjectVtbl OleInPlaceActiveObjectVtbl = {
1129};
1130
1132{
1133 return CONTAINING_RECORD(iface, WebBrowser, IOleCommandTarget_iface);
1134}
1135
1137 REFIID riid, void **ppv)
1138{
1140 return IWebBrowser2_QueryInterface(&This->IWebBrowser2_iface, riid, ppv);
1141}
1142
1144{
1146 return IWebBrowser2_AddRef(&This->IWebBrowser2_iface);
1147}
1148
1150{
1152 return IWebBrowser2_Release(&This->IWebBrowser2_iface);
1153}
1154
1156 const GUID *pguidCmdGroup, ULONG cCmds, OLECMD prgCmds[], OLECMDTEXT *pCmdText)
1157{
1159 IOleCommandTarget *cmdtrg;
1160 HRESULT hres;
1161
1162 TRACE("(%p)->(%s %u %p %p)\n", This, debugstr_guid(pguidCmdGroup), cCmds, prgCmds,
1163 pCmdText);
1164
1165 if(!This->doc_host.document)
1166 return 0x80040104;
1167
1168 /* NOTE: There are probably some commands that we should handle here
1169 * instead of forwarding to document object. */
1170
1171 hres = IUnknown_QueryInterface(This->doc_host.document, &IID_IOleCommandTarget, (void**)&cmdtrg);
1172 if(FAILED(hres))
1173 return hres;
1174
1175 hres = IOleCommandTarget_QueryStatus(cmdtrg, pguidCmdGroup, cCmds, prgCmds, pCmdText);
1176 IOleCommandTarget_Release(cmdtrg);
1177
1178 return hres;
1179}
1180
1182 const GUID *pguidCmdGroup, DWORD nCmdID, DWORD nCmdexecopt, VARIANT *pvaIn,
1183 VARIANT *pvaOut)
1184{
1186 FIXME("(%p)->(%s %d %d %s %p)\n", This, debugstr_guid(pguidCmdGroup), nCmdID,
1187 nCmdexecopt, debugstr_variant(pvaIn), pvaOut);
1188 return E_NOTIMPL;
1189}
1190
1191static const IOleCommandTargetVtbl OleCommandTargetVtbl = {
1197};
1198
1200{
1201 DWORD dpi_x;
1202 DWORD dpi_y;
1203 HDC hdc;
1204
1205 /* default aspect ratio is 96dpi / 96dpi */
1206 hdc = GetDC(0);
1207 dpi_x = GetDeviceCaps(hdc, LOGPIXELSX);
1208 dpi_y = GetDeviceCaps(hdc, LOGPIXELSY);
1209 ReleaseDC(0, hdc);
1210
1211 This->IOleObject_iface.lpVtbl = &OleObjectVtbl;
1212 This->IOleInPlaceObject_iface.lpVtbl = &OleInPlaceObjectVtbl;
1213 This->IOleControl_iface.lpVtbl = &OleControlVtbl;
1214 This->IOleInPlaceActiveObject_iface.lpVtbl = &OleInPlaceActiveObjectVtbl;
1215 This->IOleCommandTarget_iface.lpVtbl = &OleCommandTargetVtbl;
1216
1217 /* Default size is 50x20 pixels, in himetric units */
1218 This->extent.cx = MulDiv( 50, 2540, dpi_x );
1219 This->extent.cy = MulDiv( 20, 2540, dpi_y );
1220}
1221
1223{
1225}
static void * heap_alloc(size_t len)
Definition: appwiz.h:66
static BOOL heap_free(void *mem)
Definition: appwiz.h:76
#define InterlockedIncrement
Definition: armddk.h:53
#define InterlockedDecrement
Definition: armddk.h:52
static const char * wine_dbgstr_rect(const RECT *prc)
Definition: atltest.h:160
#define msg(x)
Definition: auth_time.c:54
HWND hWnd
Definition: settings.c:17
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
Definition: precomp.h:23
#define ARRAY_SIZE(A)
Definition: main.h:20
#define FIXME(fmt,...)
Definition: precomp.h:53
#define WARN(fmt,...)
Definition: precomp.h:61
const GUID IID_IUnknown
WPARAM wParam
Definition: combotst.c:138
LPARAM lParam
Definition: combotst.c:139
static HWND hwndParent
Definition: cryptui.c:300
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
#define E_INVALIDARG
Definition: ddrawi.h:101
#define E_NOTIMPL
Definition: ddrawi.h:99
#define E_FAIL
Definition: ddrawi.h:102
WORD ATOM
Definition: dimm.idl:113
#define NULL
Definition: types.h:112
#define TRUE
Definition: types.h:120
#define FALSE
Definition: types.h:117
@ VT_BOOL
Definition: compat.h:2306
@ VT_EMPTY
Definition: compat.h:2295
HRESULT WINAPI OleRegGetUserType(REFCLSID clsid, DWORD form, LPOLESTR *usertype)
Definition: ole2.c:678
void on_commandstate_change(DocHost *doc_host, LONG command, BOOL enable)
Definition: dochost.c:83
LRESULT process_dochost_tasks(DocHost *This)
Definition: dochost.c:55
void deactivate_document(DocHost *This)
Definition: dochost.c:510
void release_dochost_client(DocHost *This)
Definition: dochost.c:601
r parent
Definition: btrfs.c:3010
unsigned int BOOL
Definition: ntddk_ex.h:94
unsigned long DWORD
Definition: ntddk_ex.h:95
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
GLint GLint GLsizei width
Definition: gl.h:1546
GLuint res
Definition: glext.h:9613
#define DISPID_AMBIENT_OFFLINEIFNOTCONNECTED
Definition: idispids.h:25
#define DISPID_AMBIENT_SILENT
Definition: idispids.h:26
#define WM_DOCHOSTTASK
Definition: ieframe.h:293
HINSTANCE ieframe_instance
Definition: ieframe_main.c:32
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
#define debugstr_guid
Definition: kernel32.h:35
#define debugstr_w
Definition: kernel32.h:32
HDC hdc
Definition: main.c:9
static HDC
Definition: imagelist.c:88
static const char * debugstr_variant(const VARIANT *var)
Definition: container.c:46
HRESULT hres
Definition: protocol.c:465
static LPOLESTR
Definition: stg_prop.c:27
static VARIANTARG static DISPID
Definition: ordinal.c:52
#define DISPID_AMBIENT_DLCONTROL
Definition: mshtmdid.h:539
static BOOL silent
Definition: msiexec.c:42
_In_ HANDLE _In_ DWORD _In_ DWORD _Inout_opt_ LPOVERLAPPED _In_opt_ LPTRANSMIT_FILE_BUFFERS _In_ DWORD dwReserved
Definition: mswsock.h:95
INT WINAPI MulDiv(INT nNumber, INT nNumerator, INT nDenominator)
Definition: muldiv.c:25
unsigned int UINT
Definition: ndis.h:50
#define LOCALE_SYSTEM_DEFAULT
interface IMoniker * LPMONIKER
Definition: objfwd.h:9
interface IDataObject * LPDATAOBJECT
Definition: objfwd.h:21
#define OLEIVERB_HIDE
Definition: ole2.h:41
#define OLEIVERB_UIACTIVATE
Definition: ole2.h:42
#define OLEIVERB_INPLACEACTIVATE
Definition: ole2.h:43
#define OLEIVERB_SHOW
Definition: ole2.h:39
#define OLEIVERB_PRIMARY
Definition: ole2.h:38
#define V_BOOL(A)
Definition: oleauto.h:224
#define V_VT(A)
Definition: oleauto.h:211
#define DISPATCH_PROPERTYGET
Definition: oleauto.h:1007
const GUID IID_IOleInPlaceActiveObject
const GUID IID_IOleInPlaceSite
const GUID IID_IOleControlSite
const GUID IID_IDispatch
const GUID IID_IEnumOLEVERB
static HRESULT WINAPI InPlaceActiveObject_GetWindow(IOleInPlaceActiveObject *iface, HWND *phwnd)
Definition: oleobject.c:1048
static HRESULT WINAPI OleInPlaceObject_GetWindow(IOleInPlaceObject *iface, HWND *phwnd)
Definition: oleobject.c:856
static ULONG WINAPI OleInPlaceObject_Release(IOleInPlaceObject *iface)
Definition: oleobject.c:850
static HRESULT WINAPI OleControl_FreezeEvents(IOleControl *iface, BOOL bFreeze)
Definition: oleobject.c:1006
static HRESULT WINAPI InPlaceActiveObject_OnDocWindowActivate(IOleInPlaceActiveObject *iface, BOOL fActivate)
Definition: oleobject.c:1094
static HRESULT WINAPI OleObject_GetMiscStatus(IOleObject *iface, DWORD dwAspect, DWORD *pdwStatus)
Definition: oleobject.c:781
static HRESULT WINAPI OleObject_IsUpToDate(IOleObject *iface)
Definition: oleobject.c:715
static HRESULT WINAPI OleObject_Advise(IOleObject *iface, IAdviseSink *pAdvSink, DWORD *pdwConnection)
Definition: oleobject.c:759
static HRESULT WINAPI WBOleCommandTarget_QueryStatus(IOleCommandTarget *iface, const GUID *pguidCmdGroup, ULONG cCmds, OLECMD prgCmds[], OLECMDTEXT *pCmdText)
Definition: oleobject.c:1155
static HRESULT activate_inplace(WebBrowser *This, IOleClientSite *active_site)
Definition: oleobject.c:138
static HRESULT WINAPI OleObject_GetMoniker(IOleObject *iface, DWORD dwAssign, DWORD dwWhichMoniker, LPMONIKER *ppmk)
Definition: oleobject.c:623
static void notify_on_focus(WebBrowser *This, BOOL got_focus)
Definition: oleobject.c:52
static HRESULT WINAPI OleInPlaceObject_QueryInterface(IOleInPlaceObject *iface, REFIID riid, LPVOID *ppobj)
Definition: oleobject.c:837
static HRESULT WINAPI InPlaceActiveObject_ContextSensitiveHelp(IOleInPlaceActiveObject *iface, BOOL fEnterMode)
Definition: oleobject.c:1055
void WebBrowser_OleObject_Destroy(WebBrowser *This)
Definition: oleobject.c:1222
static HRESULT WINAPI EnumOLEVERB_QueryInterface(IEnumOLEVERB *iface, REFIID riid, void **ppv)
Definition: oleobject.c:332
static HRESULT WINAPI OleObject_QueryInterface(IOleObject *iface, REFIID riid, void **ppv)
Definition: oleobject.c:439
static HRESULT WINAPI InPlaceActiveObject_OnFrameWindowActivate(IOleInPlaceActiveObject *iface, BOOL fActivate)
Definition: oleobject.c:1086
static HRESULT WINAPI OleObject_DoVerb(IOleObject *iface, LONG iVerb, struct tagMSG *lpmsg, LPOLECLIENTSITE pActiveSite, LONG lindex, HWND hwndParent, LPCRECT lprcPosRect)
Definition: oleobject.c:647
static ULONG WINAPI EnumOLEVERB_AddRef(IEnumOLEVERB *iface)
Definition: oleobject.c:352
static HRESULT on_silent_change(WebBrowser *This)
Definition: oleobject.c:272
static HRESULT WINAPI OleObject_EnumAdvise(IOleObject *iface, IEnumSTATDATA **ppenumAdvise)
Definition: oleobject.c:774
static HRESULT WINAPI OleControl_GetControlInfo(IOleControl *iface, LPCONTROLINFO pCI)
Definition: oleobject.c:965
static ULONG WINAPI OleObject_AddRef(IOleObject *iface)
Definition: oleobject.c:445
static ULONG WINAPI InPlaceActiveObject_AddRef(IOleInPlaceActiveObject *iface)
Definition: oleobject.c:1036
static HRESULT WINAPI WBOleCommandTarget_QueryInterface(IOleCommandTarget *iface, REFIID riid, void **ppv)
Definition: oleobject.c:1136
void WebBrowser_OleObject_Init(WebBrowser *This)
Definition: oleobject.c:1199
static LRESULT resize_window(WebBrowser *This, LONG width, LONG height)
Definition: oleobject.c:43
static WebBrowser * impl_from_IOleInPlaceObject(IOleInPlaceObject *iface)
Definition: oleobject.c:832
static HRESULT WINAPI OleObject_GetClipboardData(IOleObject *iface, DWORD dwReserved, LPDATAOBJECT *ppDataObject)
Definition: oleobject.c:639
static const IOleInPlaceObjectVtbl OleInPlaceObjectVtbl
Definition: oleobject.c:924
static ATOM shell_embedding_atom
Definition: oleobject.c:41
static ULONG WINAPI WBOleCommandTarget_AddRef(IOleCommandTarget *iface)
Definition: oleobject.c:1143
static ULONG WINAPI InPlaceActiveObject_Release(IOleInPlaceActiveObject *iface)
Definition: oleobject.c:1042
static HRESULT WINAPI OleInPlaceObject_ContextSensitiveHelp(IOleInPlaceObject *iface, BOOL fEnterMode)
Definition: oleobject.c:866
static HRESULT activate_ui(WebBrowser *This, IOleClientSite *active_site)
Definition: oleobject.c:200
static const IOleInPlaceActiveObjectVtbl OleInPlaceActiveObjectVtbl
Definition: oleobject.c:1118
static HRESULT WINAPI OleObject_GetExtent(IOleObject *iface, DWORD dwDrawAspect, SIZEL *psizel)
Definition: oleobject.c:748
static ULONG WINAPI WBOleCommandTarget_Release(IOleCommandTarget *iface)
Definition: oleobject.c:1149
static HRESULT WINAPI WBOleCommandTarget_Exec(IOleCommandTarget *iface, const GUID *pguidCmdGroup, DWORD nCmdID, DWORD nCmdexecopt, VARIANT *pvaIn, VARIANT *pvaOut)
Definition: oleobject.c:1181
static WebBrowser * impl_from_IOleControl(IOleControl *iface)
Definition: oleobject.c:941
static HRESULT WINAPI OleObject_GetUserType(IOleObject *iface, DWORD dwFormOfType, LPOLESTR *pszUserType)
Definition: oleobject.c:729
static HRESULT WINAPI OleControl_OnAmbientPropertyChange(IOleControl *iface, DISPID dispID)
Definition: oleobject.c:982
static WebBrowser * impl_from_IOleObject(IOleObject *iface)
Definition: oleobject.c:434
static ULONG WINAPI EnumOLEVERB_Release(IEnumOLEVERB *iface)
Definition: oleobject.c:362
static HRESULT WINAPI EnumOLEVERB_Reset(IEnumOLEVERB *iface)
Definition: oleobject.c:403
static HRESULT WINAPI EnumOLEVERB_Next(IEnumOLEVERB *iface, ULONG celt, OLEVERB *rgelt, ULONG *pceltFetched)
Definition: oleobject.c:375
static ULONG WINAPI OleObject_Release(IOleObject *iface)
Definition: oleobject.c:451
static HRESULT WINAPI OleInPlaceObject_ReactivateAndUndo(IOleInPlaceObject *iface)
Definition: oleobject.c:917
static HRESULT WINAPI OleObject_SetHostNames(IOleObject *iface, LPCOLESTR szContainerApp, LPCOLESTR szContainerObj)
Definition: oleobject.c:571
static HRESULT WINAPI InPlaceActiveObject_ResizeBorder(IOleInPlaceActiveObject *iface, LPCRECT lprcBorder, IOleInPlaceUIWindow *pUIWindow, BOOL fFrameWindow)
Definition: oleobject.c:1102
static HRESULT WINAPI OleObject_GetUserClassID(IOleObject *iface, CLSID *pClsid)
Definition: oleobject.c:722
static HRESULT WINAPI OleObject_GetClientSite(IOleObject *iface, LPOLECLIENTSITE *ppClientSite)
Definition: oleobject.c:555
static HRESULT WINAPI EnumOLEVERB_Clone(IEnumOLEVERB *iface, IEnumOLEVERB **ppenum)
Definition: oleobject.c:413
static ULONG WINAPI OleControl_Release(IOleControl *iface)
Definition: oleobject.c:959
static WebBrowser * impl_from_IOleCommandTarget(IOleCommandTarget *iface)
Definition: oleobject.c:1131
static HRESULT WINAPI OleInPlaceObject_InPlaceDeactivate(IOleInPlaceObject *iface)
Definition: oleobject.c:874
static const IOleObjectVtbl OleObjectVtbl
Definition: oleobject.c:800
static WebBrowser * impl_from_IOleInPlaceActiveObject(IOleInPlaceActiveObject *iface)
Definition: oleobject.c:1024
static HRESULT on_offlineconnected_change(WebBrowser *This)
Definition: oleobject.c:258
static HRESULT WINAPI OleObject_SetMoniker(IOleObject *iface, DWORD dwWhichMoniker, IMoniker *pmk)
Definition: oleobject.c:616
static void create_shell_embedding_hwnd(WebBrowser *This)
Definition: oleobject.c:97
static const IEnumOLEVERBVtbl EnumOLEVERBVtbl
Definition: oleobject.c:420
static ULONG WINAPI OleInPlaceObject_AddRef(IOleInPlaceObject *iface)
Definition: oleobject.c:844
static HRESULT WINAPI InPlaceActiveObject_QueryInterface(IOleInPlaceActiveObject *iface, REFIID riid, void **ppv)
Definition: oleobject.c:1029
static HRESULT WINAPI InPlaceActiveObject_EnableModeless(IOleInPlaceActiveObject *iface, BOOL fEnable)
Definition: oleobject.c:1110
static HRESULT WINAPI OleObject_EnumVerbs(IOleObject *iface, IEnumOLEVERB **ppEnumOleVerb)
Definition: oleobject.c:689
static HRESULT WINAPI OleObject_Update(IOleObject *iface)
Definition: oleobject.c:708
static ULONG WINAPI OleControl_AddRef(IOleControl *iface)
Definition: oleobject.c:953
static HRESULT WINAPI OleObject_SetExtent(IOleObject *iface, DWORD dwDrawAspect, SIZEL *psizel)
Definition: oleobject.c:737
static HRESULT WINAPI OleControl_QueryInterface(IOleControl *iface, REFIID riid, LPVOID *ppobj)
Definition: oleobject.c:946
static HRESULT WINAPI OleInPlaceObject_SetObjectRects(IOleInPlaceObject *iface, LPCRECT lprcPosRect, LPCRECT lprcClipRect)
Definition: oleobject.c:894
HWND WINAPI SHSetParentHwnd(HWND hWnd, HWND hWndParent)
Definition: ordinal.c:1158
static const IOleCommandTargetVtbl OleCommandTargetVtbl
Definition: oleobject.c:1191
static HRESULT WINAPI OleObject_SetClientSite(IOleObject *iface, LPOLECLIENTSITE pClientSite)
Definition: oleobject.c:457
static HRESULT WINAPI EnumOLEVERB_Skip(IEnumOLEVERB *iface, ULONG celt)
Definition: oleobject.c:396
static HRESULT WINAPI OleObject_InitFromData(IOleObject *iface, LPDATAOBJECT pDataObject, BOOL fCreation, DWORD dwReserved)
Definition: oleobject.c:631
static HRESULT WINAPI OleObject_SetColorScheme(IOleObject *iface, LOGPALETTE *pLogpal)
Definition: oleobject.c:793
static void release_client_site(WebBrowser *This, BOOL destroy_win)
Definition: oleobject.c:286
static HRESULT WINAPI OleObject_Unadvise(IOleObject *iface, DWORD dwConnection)
Definition: oleobject.c:767
static HRESULT WINAPI OleObject_Close(IOleObject *iface, DWORD dwSaveOption)
Definition: oleobject.c:582
static HRESULT WINAPI InPlaceActiveObject_TranslateAccelerator(IOleInPlaceActiveObject *iface, LPMSG lpmsg)
Definition: oleobject.c:1062
static EnumOLEVERB * impl_from_IEnumOLEVERB(IEnumOLEVERB *iface)
Definition: oleobject.c:327
static const IOleControlVtbl OleControlVtbl
Definition: oleobject.c:1013
static HRESULT WINAPI OleControl_OnMnemonic(IOleControl *iface, struct tagMSG *pMsg)
Definition: oleobject.c:975
static HRESULT WINAPI OleInPlaceObject_UIDeactivate(IOleInPlaceObject *iface)
Definition: oleobject.c:887
static HRESULT get_client_disp_property(IOleClientSite *client, DISPID dispid, VARIANT *res)
Definition: oleobject.c:233
static LRESULT WINAPI shell_embedding_proc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
Definition: oleobject.c:68
#define LOWORD(l)
Definition: pedump.c:82
#define WS_CHILD
Definition: pedump.c:617
#define WS_MAXIMIZEBOX
Definition: pedump.c:632
#define WS_TABSTOP
Definition: pedump.c:634
#define WS_POPUP
Definition: pedump.c:616
long LONG
Definition: pedump.c:60
#define WS_CLIPSIBLINGS
Definition: pedump.c:618
#define WS_CLIPCHILDREN
Definition: pedump.c:619
#define IsEqualGUID(rguid1, rguid2)
Definition: guiddef.h:147
#define REFIID
Definition: guiddef.h:118
#define IID_NULL
Definition: guiddef.h:98
@ OLEMISC_INSIDEOUT
Definition: actctx.c:88
@ OLEMISC_ACTIVATEWHENVISIBLE
Definition: actctx.c:89
@ OLEMISC_SETCLIENTSITEFIRST
Definition: actctx.c:98
@ OLEMISC_RECOMPOSEONRESIZE
Definition: actctx.c:81
@ OLEMISC_CANTLINKINSIDE
Definition: actctx.c:85
static FILE * client
Definition: client.c:41
HRESULT hr
Definition: shlfolder.c:183
#define TRACE(s)
Definition: solgame.cpp:4
IEnumOLEVERB IEnumOLEVERB_iface
Definition: oleobject.c:322
HINSTANCE hInstance
Definition: winuser.h:3224
Definition: send.c:48
LONG right
Definition: windef.h:308
LONG bottom
Definition: windef.h:309
LONG top
Definition: windef.h:307
LONG left
Definition: windef.h:306
#define CONTAINING_RECORD(address, type, field)
Definition: typedefs.h:260
uint32_t ULONG
Definition: typedefs.h:59
#define HIWORD(l)
Definition: typedefs.h:247
void WINAPI VariantInit(VARIANTARG *pVarg)
Definition: variant.c:568
int ret
_In_ LONG _In_ HWND hwnd
Definition: winddi.h:4023
LONG_PTR LPARAM
Definition: windef.h:208
LONG_PTR LRESULT
Definition: windef.h:209
UINT_PTR WPARAM
Definition: windef.h:207
#define WINAPI
Definition: msvc.h:6
#define S_FALSE
Definition: winerror.h:2357
#define E_NOINTERFACE
Definition: winerror.h:2364
int WINAPI GetDeviceCaps(_In_opt_ HDC, _In_ int)
#define LOGPIXELSY
Definition: wingdi.h:719
#define LOGPIXELSX
Definition: wingdi.h:718
int WINAPI ReleaseDC(_In_opt_ HWND, _In_ HDC)
#define SW_HIDE
Definition: winuser.h:771
#define SWP_NOACTIVATE
Definition: winuser.h:1245
#define COLOR_WINDOW
Definition: winuser.h:921
BOOL WINAPI ShowWindow(_In_ HWND, _In_ int)
LRESULT WINAPI DefWindowProcW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
#define WM_CREATE
Definition: winuser.h:1611
BOOL WINAPI SetWindowPos(_In_ HWND, _In_opt_ HWND, _In_ int, _In_ int, _In_ int, _In_ int, _In_ UINT)
#define WM_SIZE
Definition: winuser.h:1614
#define WM_SETFOCUS
Definition: winuser.h:1616
#define CS_DBLCLKS
Definition: winuser.h:651
HWND WINAPI SetFocus(_In_opt_ HWND)
HWND WINAPI CreateWindowExW(_In_ DWORD dwExStyle, _In_opt_ LPCWSTR lpClassName, _In_opt_ LPCWSTR lpWindowName, _In_ DWORD dwStyle, _In_ int X, _In_ int Y, _In_ int nWidth, _In_ int nHeight, _In_opt_ HWND hWndParent, _In_opt_ HMENU hMenu, _In_opt_ HINSTANCE hInstance, _In_opt_ LPVOID lpParam)
BOOL WINAPI SetPropW(_In_ HWND, _In_ LPCWSTR, _In_opt_ HANDLE)
ATOM WINAPI RegisterClassExW(_In_ CONST WNDCLASSEXW *)
#define SWP_SHOWWINDOW
Definition: winuser.h:1251
#define WS_EX_WINDOWEDGE
Definition: winuser.h:407
HDC WINAPI GetDC(_In_opt_ HWND)
HANDLE WINAPI GetPropW(_In_ HWND, _In_ LPCWSTR)
#define SW_SHOW
Definition: winuser.h:778
#define SWP_NOZORDER
Definition: winuser.h:1250
BOOL WINAPI DestroyWindow(_In_ HWND)
#define WM_KILLFOCUS
Definition: winuser.h:1617
__wchar_t WCHAR
Definition: xmlstorage.h:180