ReactOS 0.4.15-dev-8419-g7f0e8a3
main.c
Go to the documentation of this file.
1/*
2 * MSHTML Class Factory
3 *
4 * Copyright 2002 Lionel Ulmer
5 * Copyright 2003 Mike McCormack
6 * Copyright 2005 Jacek Caban
7 *
8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Lesser General Public
10 * License as published by the Free Software Foundation; either
11 * version 2.1 of the License, or (at your option) any later version.
12 *
13 * This library is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Lesser General Public License for more details.
17 *
18 * You should have received a copy of the GNU Lesser General Public
19 * License along with this library; if not, write to the Free Software
20 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
21 */
22
23#include "mshtml_private.h"
24
25#include <advpub.h>
26#include <rpcproxy.h>
27#include <mlang.h>
28#include <initguid.h>
29
32
38void (__cdecl *note_cc_edge)(nsISupports*,const char*,nsCycleCollectionTraversalCallback*);
39
43static IMultiLanguage2 *mlang;
44
46{
47 MIMECSETINFO info;
49
50 if(!mlang) {
51 IMultiLanguage2 *new_mlang;
52
53 hres = CoCreateInstance(&CLSID_CMultiLanguage, NULL, CLSCTX_INPROC_SERVER,
54 &IID_IMultiLanguage2, (void**)&new_mlang);
55 if(FAILED(hres)) {
56 ERR("Could not create CMultiLanguage instance\n");
57 return CP_UTF8;
58 }
59
60 if(InterlockedCompareExchangePointer((void**)&mlang, new_mlang, NULL))
61 IMultiLanguage2_Release(new_mlang);
62 }
63
64 hres = IMultiLanguage2_GetCharsetInfo(mlang, charset, &info);
65 if(FAILED(hres)) {
66 FIXME("GetCharsetInfo failed: %08x\n", hres);
67 return CP_UTF8;
68 }
69
70 return info.uiInternetEncoding;
71}
72
73static void thread_detach(void)
74{
76
78 if(!thread_data)
79 return;
80
81 if(thread_data->thread_hwnd)
82 DestroyWindow(thread_data->thread_hwnd);
83
85}
86
87static void free_strings(void)
88{
89 unsigned int i;
90 for(i = 0; i < sizeof(status_strings)/sizeof(*status_strings); i++)
92}
93
94static void process_detach(void)
95{
98
99 if(shdoclc)
103 if(display_dc)
105 if(mlang)
106 IMultiLanguage2_Release(mlang);
107
108 free_strings();
109}
110
112{
113 int index = id - IDS_STATUS_FIRST;
115 DWORD len;
116
117 if(!doc->frame)
118 return;
119
120 if(!p) {
121 len = 255;
122 p = heap_alloc(len * sizeof(WCHAR));
123 len = LoadStringW(hInst, id, p, len) + 1;
124 p = heap_realloc(p, len * sizeof(WCHAR));
126 heap_free(p);
128 }
129 }
130
131 if(arg) {
132 WCHAR *buf;
133
134 len = lstrlenW(p) + lstrlenW(arg) - 1;
135 buf = heap_alloc(len * sizeof(WCHAR));
136
137 snprintfW(buf, len, p, arg);
138
139 p = buf;
140 }
141
142 IOleInPlaceFrame_SetStatusText(doc->frame, p);
143
144 if(arg)
145 heap_free(p);
146}
147
149{
152
153 hres = IUnknown_QueryInterface(unk, &IID_IServiceProvider, (void**)&sp);
154 if(FAILED(hres))
155 return hres;
156
157 hres = IServiceProvider_QueryService(sp, guid_service, riid, ppv);
158 IServiceProvider_Release(sp);
159 return hres;
160}
161
163{
164 static const WCHAR wszShdoclc[] =
165 {'s','h','d','o','c','l','c','.','d','l','l',0};
166
167 if(shdoclc)
168 return shdoclc;
169
171}
172
174{
175 static const WCHAR displayW[] = {'D','I','S','P','L','A','Y',0};
176
177 if(!display_dc) {
178 HDC hdc;
179
183 }
184
185 return display_dc;
186}
187
189{
190 switch(fdwReason) {
192 hInst = hInstDLL;
193 break;
195 if (reserved) break;
197 break;
200 break;
201 }
202 return TRUE;
203}
204
205/***********************************************************
206 * ClassFactory implementation
207 */
209typedef struct {
214
216{
217 return CONTAINING_RECORD(iface, ClassFactory, IClassFactory_iface);
218}
219
221{
223 IClassFactory_AddRef(iface);
224 *ppvObject = iface;
225 return S_OK;
226 }
227
228 WARN("not supported iid %s\n", debugstr_mshtml_guid(riid));
229 *ppvObject = NULL;
230 return E_NOINTERFACE;
231}
232
234{
237 TRACE("(%p) ref = %u\n", This, ref);
238 return ref;
239}
240
242{
245
246 TRACE("(%p) ref = %u\n", This, ref);
247
248 if(!ref) {
250 }
251
252 return ref;
253}
254
256 REFIID riid, void **ppvObject)
257{
259 return This->fnCreateInstance(pUnkOuter, riid, ppvObject);
260}
261
263{
264 TRACE("(%p)->(%x)\n", iface, dolock);
265
266 /* We never unload the DLL. See DllCanUnloadNow(). */
267 return S_OK;
268}
269
270static const IClassFactoryVtbl HTMLClassFactoryVtbl = {
276};
277
279{
282
283 ret->IClassFactory_iface.lpVtbl = &HTMLClassFactoryVtbl;
284 ret->ref = 0;
285 ret->fnCreateInstance = fnCreateInstance;
286
287 hres = IClassFactory_QueryInterface(&ret->IClassFactory_iface, riid, ppv);
288 if(FAILED(hres)) {
289 heap_free(ret);
290 *ppv = NULL;
291 }
292 return hres;
293}
294
295/******************************************************************
296 * DllGetClassObject (MSHTML.@)
297 */
299{
300 if(IsEqualGUID(&CLSID_HTMLDocument, rclsid)) {
301 TRACE("(CLSID_HTMLDocument %s %p)\n", debugstr_mshtml_guid(riid), ppv);
303 }else if(IsEqualGUID(&CLSID_AboutProtocol, rclsid)) {
304 TRACE("(CLSID_AboutProtocol %s %p)\n", debugstr_mshtml_guid(riid), ppv);
305 return ProtocolFactory_Create(rclsid, riid, ppv);
306 }else if(IsEqualGUID(&CLSID_JSProtocol, rclsid)) {
307 TRACE("(CLSID_JSProtocol %s %p)\n", debugstr_mshtml_guid(riid), ppv);
308 return ProtocolFactory_Create(rclsid, riid, ppv);
309 }else if(IsEqualGUID(&CLSID_MailtoProtocol, rclsid)) {
310 TRACE("(CLSID_MailtoProtocol %s %p)\n", debugstr_mshtml_guid(riid), ppv);
311 return ProtocolFactory_Create(rclsid, riid, ppv);
312 }else if(IsEqualGUID(&CLSID_ResProtocol, rclsid)) {
313 TRACE("(CLSID_ResProtocol %s %p)\n", debugstr_mshtml_guid(riid), ppv);
314 return ProtocolFactory_Create(rclsid, riid, ppv);
315 }else if(IsEqualGUID(&CLSID_SysimageProtocol, rclsid)) {
316 TRACE("(CLSID_SysimageProtocol %s %p)\n", debugstr_mshtml_guid(riid), ppv);
317 return ProtocolFactory_Create(rclsid, riid, ppv);
318 }else if(IsEqualGUID(&CLSID_HTMLLoadOptions, rclsid)) {
319 TRACE("(CLSID_HTMLLoadOptions %s %p)\n", debugstr_mshtml_guid(riid), ppv);
321 }
322
323 FIXME("Unknown class %s\n", debugstr_guid(rclsid));
325}
326
327/******************************************************************
328 * DllCanUnloadNow (MSHTML.@)
329 */
331{
332 TRACE("()\n");
333 /* The cost of keeping this DLL in memory is small. */
334 return S_FALSE;
335}
336
337/***********************************************************************
338 * RunHTMLApplication (MSHTML.@)
339 *
340 * Appears to have the same prototype as WinMain.
341 */
343 LPSTR szCmdLine, INT nCmdShow )
344{
345 FIXME("%p %p %s %d\n", hinst, hPrevInst, debugstr_a(szCmdLine), nCmdShow );
346 return 0;
347}
348
349/***********************************************************************
350 * RNIGetCompatibleVersion (MSHTML.@)
351 */
353{
354 TRACE("()\n");
355 return 0x20000;
356}
357
358/***********************************************************************
359 * DllInstall (MSHTML.@)
360 */
362{
363 FIXME("stub %d %s: returning S_OK\n", bInstall, debugstr_w(cmdline));
364 return S_OK;
365}
366
367/***********************************************************************
368 * ShowHTMLDialog (MSHTML.@)
369 */
371 WCHAR *pchOptions, VARIANT *pvarArgOut)
372{
373 FIXME("(%p %p %p %s %p)\n", hwndParent, pMk, pvarArgIn, debugstr_w(pchOptions), pvarArgOut);
374 return E_NOTIMPL;
375}
376
377/***********************************************************************
378 * PrintHTML (MSHTML.@)
379 */
381{
382 FIXME("(%p %p %s %x)\n", hwnd, handle, debugstr_a(cmdline), show);
383}
384
385DEFINE_GUID(CLSID_CBackgroundPropertyPage, 0x3050F232, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B);
386DEFINE_GUID(CLSID_CCDAnchorPropertyPage, 0x3050F1FC, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B);
387DEFINE_GUID(CLSID_CCDGenericPropertyPage, 0x3050F17F, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B);
388DEFINE_GUID(CLSID_CDwnBindInfo, 0x3050F3C2, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B);
389DEFINE_GUID(CLSID_CHiFiUses, 0x5AAF51B3, 0xB1F0, 0x11D1, 0xB6,0xAB, 0x00,0xA0,0xC9,0x08,0x33,0xE9);
390DEFINE_GUID(CLSID_CHtmlComponentConstructor, 0x3050F4F8, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B);
391DEFINE_GUID(CLSID_CInlineStylePropertyPage, 0x3050F296, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B);
392DEFINE_GUID(CLSID_CPeerHandler, 0x5AAF51B2, 0xB1F0, 0x11D1, 0xB6,0xAB, 0x00,0xA0,0xC9,0x08,0x33,0xE9);
393DEFINE_GUID(CLSID_CRecalcEngine, 0x3050F499, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B);
394DEFINE_GUID(CLSID_CSvrOMUses, 0x3050F4F0, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B);
395DEFINE_GUID(CLSID_CrSource, 0x65014010, 0x9F62, 0x11D1, 0xA6,0x51, 0x00,0x60,0x08,0x11,0xD5,0xCE);
396DEFINE_GUID(CLSID_ExternalFrameworkSite, 0x3050F163, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B);
397DEFINE_GUID(CLSID_HTADocument, 0x3050F5C8, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B);
398DEFINE_GUID(CLSID_HTMLPluginDocument, 0x25336921, 0x03F9, 0x11CF, 0x8F,0xD0, 0x00,0xAA,0x00,0x68,0x6F,0x13);
399DEFINE_GUID(CLSID_HTMLPopup, 0x3050F667, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B);
400DEFINE_GUID(CLSID_HTMLPopupDoc, 0x3050F67D, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B);
401DEFINE_GUID(CLSID_HTMLServerDoc, 0x3050F4E7, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B);
402DEFINE_GUID(CLSID_IImageDecodeFilter, 0x607FD4E8, 0x0A03, 0x11D1, 0xAB,0x1D, 0x00,0xC0,0x4F,0xC9,0xB3,0x04);
403DEFINE_GUID(CLSID_IImgCtx, 0x3050F3D6, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B);
404DEFINE_GUID(CLSID_IntDitherer, 0x05F6FE1A, 0xECEF, 0x11D0, 0xAA,0xE7, 0x00,0xC0,0x4F,0xC9,0xB3,0x04);
405DEFINE_GUID(CLSID_MHTMLDocument, 0x3050F3D9, 0x98B5, 0x11CF, 0xBB,0x82, 0x00,0xAA,0x00,0xBD,0xCE,0x0B);
406DEFINE_GUID(CLSID_TridentAPI, 0x429AF92C, 0xA51F, 0x11D2, 0x86,0x1E, 0x00,0xC0,0x4F,0xA3,0x5C,0x89);
407
408#define INF_SET_ID(id) \
409 do \
410 { \
411 static CHAR name[] = #id; \
412 \
413 pse[i].pszName = name; \
414 clsids[i++] = &id; \
415 } while (0)
416
417#define INF_SET_CLSID(clsid) INF_SET_ID(CLSID_ ## clsid)
418
419static HRESULT register_server(BOOL do_register)
420{
422 HMODULE hAdvpack;
423 HRESULT (WINAPI *pRegInstall)(HMODULE hm, LPCSTR pszSection, const STRTABLEA* pstTable);
424 STRTABLEA strtable;
425 STRENTRYA pse[35];
426 static CLSID const *clsids[35];
427 unsigned int i = 0;
428
429 static const WCHAR wszAdvpack[] = {'a','d','v','p','a','c','k','.','d','l','l',0};
430
431 TRACE("(%x)\n", do_register);
432
434 INF_SET_CLSID(CAnchorBrowsePropertyPage);
436 INF_SET_CLSID(CCDAnchorPropertyPage);
438 INF_SET_CLSID(CDocBrowsePropertyPage);
441 INF_SET_CLSID(CHtmlComponentConstructor);
443 INF_SET_CLSID(CInlineStylePropertyPage);
445 INF_SET_CLSID(CRecalcEngine);
446 INF_SET_CLSID(CSvrOMUses);
448 INF_SET_CLSID(ExternalFrameworkSite);
453 INF_SET_CLSID(HTMLPopup);
455 INF_SET_CLSID(HTMLServerDoc);
457 INF_SET_CLSID(IImageDecodeFilter);
460 INF_SET_CLSID(JSProtocol);
461 INF_SET_CLSID(MHTMLDocument);
464 INF_SET_CLSID(Scriptlet);
466 INF_SET_CLSID(TridentAPI);
467 INF_SET_ID(LIBID_MSHTML);
468
469 for(i=0; i < sizeof(pse)/sizeof(pse[0]); i++) {
470 pse[i].pszValue = heap_alloc(39);
471 sprintf(pse[i].pszValue, "{%08X-%04X-%04X-%02X%02X-%02X%02X%02X%02X%02X%02X}",
472 clsids[i]->Data1, clsids[i]->Data2, clsids[i]->Data3, clsids[i]->Data4[0],
473 clsids[i]->Data4[1], clsids[i]->Data4[2], clsids[i]->Data4[3], clsids[i]->Data4[4],
474 clsids[i]->Data4[5], clsids[i]->Data4[6], clsids[i]->Data4[7]);
475 }
476
477 strtable.cEntries = sizeof(pse)/sizeof(pse[0]);
478 strtable.pse = pse;
479
480 hAdvpack = LoadLibraryW(wszAdvpack);
481 pRegInstall = (void *)GetProcAddress(hAdvpack, "RegInstall");
482
483 hres = pRegInstall(hInst, do_register ? "RegisterDll" : "UnregisterDll", &strtable);
484
485 FreeLibrary(hAdvpack);
486
487 for(i=0; i < sizeof(pse)/sizeof(pse[0]); i++)
488 heap_free(pse[i].pszValue);
489
490 if(FAILED(hres)) {
491 ERR("RegInstall failed: %08x\n", hres);
492 return hres;
493 }
494
495 if(do_register) {
497
498 static const WCHAR wszMSHTML[] = {'m','s','h','t','m','l','.','t','l','b',0};
499
501 if(SUCCEEDED(hres))
502 ITypeLib_Release(typelib);
503 }else {
504 hres = UnRegisterTypeLib(&LIBID_MSHTML, 4, 0, LOCALE_SYSTEM_DEFAULT, SYS_WIN32);
505 }
506
507 if(FAILED(hres))
508 ERR("typelib registration failed: %08x\n", hres);
509
510 return hres;
511}
512
513#undef INF_SET_CLSID
514#undef INF_SET_ID
515
516/***********************************************************************
517 * DllRegisterServer (MSHTML.@)
518 */
520{
522
524 if(SUCCEEDED(hres))
526 if(SUCCEEDED(hres))
527 load_gecko();
528
529 return hres;
530}
531
532/***********************************************************************
533 * DllUnregisterServer (MSHTML.@)
534 */
536{
539 return hres;
540}
541
542const char *debugstr_mshtml_guid(const GUID *iid)
543{
544#define X(x) if(IsEqualGUID(iid, &x)) return #x
545 X(DIID_HTMLDocumentEvents);
546 X(DIID_HTMLDocumentEvents2);
547 X(DIID_HTMLTableEvents);
548 X(DIID_HTMLTextContainerEvents);
549 X(IID_HTMLPluginContainer);
552 X(IID_ICustomDoc);
554 X(IID_IDispatchEx);
555 X(IID_IDispatchJS);
556 X(IID_UndocumentedScriptIface);
558 X(IID_IEnumVARIANT);
559 X(IID_IHlinkTarget);
560 X(IID_IHTMLDocument6);
561 X(IID_IHTMLDocument7);
562 X(IID_IHTMLEditServices);
563 X(IID_IHTMLFramesCollection2);
564 X(IID_IHTMLPrivateWindow);
565 X(IID_IHtmlLoadOptions);
566 X(IID_IInternetHostSecurityManager);
567 X(IID_IMonikerProp);
568 X(IID_IObjectIdentity);
569 X(IID_IObjectSafety);
572 X(IID_IOleCommandTarget);
574 X(IID_IOleDocument);
575 X(IID_IOleDocumentView);
579 X(IID_IOleInPlaceObjectWindowless);
583 X(IID_IOptionArray);
586 X(IID_IPersistHistory);
587 X(IID_IPersistMoniker);
591 X(IID_IServiceProvider);
592 X(IID_ISupportErrorInfo);
593 X(IID_ITargetContainer);
594 X(IID_ITravelLogClient);
598 X(IID_IViewObjectEx);
599 X(IID_nsCycleCollectionISupports);
600 X(IID_nsXPCOMCycleCollectionParticipant);
601#define XIID(x) X(IID_##x);
602#define XDIID(x) X(DIID_##x);
604#undef XIID
605#undef XDIID
606#undef X
607
608 return debugstr_guid(iid);
609}
#define __cdecl
Definition: accygwin.h:79
static ITypeLib * typelib
Definition: apps.c:108
void release_typelib(void)
Definition: apps.c:159
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
DWORD WINAPI RunHTMLApplication(HINSTANCE hinst, HINSTANCE hPrevInst, LPSTR szCmdLine, int nCmdShow)
#define index(s, c)
Definition: various.h:29
#define FIXME(fmt,...)
Definition: precomp.h:53
#define WARN(fmt,...)
Definition: precomp.h:61
#define ERR(fmt,...)
Definition: precomp.h:57
const GUID IID_IUnknown
const GUID IID_IClassFactory
CFF_Charset charset
Definition: cffcmap.c:138
const CLSID CLSID_CCDGenericPropertyPage
static HWND hwndParent
Definition: cryptui.c:300
#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
BOOL WINAPI DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID lpReserved)
Definition: main.c:26
HRESULT WINAPI DllRegisterServer(void)
Definition: main.c:212
HRESULT WINAPI DllUnregisterServer(void)
Definition: main.c:220
HRESULT WINAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID *ppv)
Definition: main.c:166
HRESULT WINAPI DllCanUnloadNow(void)
Definition: main.c:204
static IClassFactoryImpl * impl_from_IClassFactory(IClassFactory *iface)
Definition: main.c:63
#define DLL_THREAD_DETACH
Definition: compat.h:133
#define DLL_PROCESS_ATTACH
Definition: compat.h:131
#define DLL_PROCESS_DETACH
Definition: compat.h:130
#define GetProcAddress(x, y)
Definition: compat.h:753
#define FreeLibrary(x)
Definition: compat.h:748
OLECHAR * BSTR
Definition: compat.h:2293
#define LoadLibraryW(x)
Definition: compat.h:747
#define lstrlenW
Definition: compat.h:750
HINSTANCE WINAPI DECLSPEC_HOTPATCH LoadLibraryExW(LPCWSTR lpLibFileName, HANDLE hFile, DWORD dwFlags)
Definition: loader.c:288
BOOL WINAPI TlsFree(IN DWORD Index)
Definition: thread.c:1166
HRESULT HTMLDocument_Create(IUnknown *pUnkOuter, REFIID riid, void **ppvObject)
Definition: htmldoc.c:4821
static HRESULT ClassFactory_Create(REFIID riid, void **ppv, CreateInstanceFunc fnCreateInstance)
Definition: main.c:278
static HRESULT WINAPI ClassFactory_LockServer(IClassFactory *iface, BOOL dolock)
Definition: main.c:262
static const IClassFactoryVtbl HTMLClassFactoryVtbl
Definition: main.c:270
static IMultiLanguage2 * mlang
Definition: main.c:43
DWORD WINAPI RNIGetCompatibleVersion(void)
Definition: main.c:352
HRESULT WINAPI ShowHTMLDialog(HWND hwndParent, IMoniker *pMk, VARIANT *pvarArgIn, WCHAR *pchOptions, VARIANT *pvarArgOut)
Definition: main.c:370
static HRESULT WINAPI ClassFactory_QueryInterface(IClassFactory *iface, REFGUID riid, void **ppvObject)
Definition: main.c:220
HRESULT do_query_service(IUnknown *unk, REFGUID guid_service, REFIID riid, void **ppv)
Definition: main.c:148
static ULONG WINAPI ClassFactory_Release(IClassFactory *iface)
Definition: main.c:241
UINT cp_from_charset_string(BSTR charset)
Definition: main.c:45
#define X(x)
#define INF_SET_ID(id)
Definition: main.c:408
const CCObjCallback nsISupports nsISupports ExternalCycleCollectionParticipant nsrefcnt
Definition: main.c:36
#define INF_SET_CLSID(clsid)
Definition: main.c:417
const char * debugstr_mshtml_guid(const GUID *iid)
Definition: main.c:542
static void thread_detach(void)
Definition: main.c:73
HRESULT WINAPI DllInstall(BOOL bInstall, LPCWSTR cmdline)
Definition: main.c:361
static WCHAR * status_strings[IDS_STATUS_LAST-IDS_STATUS_FIRST+1]
Definition: main.c:42
void set_statustext(HTMLDocumentObj *doc, INT id, LPCWSTR arg)
Definition: main.c:111
static ULONG WINAPI ClassFactory_AddRef(IClassFactory *iface)
Definition: main.c:233
DWORD mshtml_tls
Definition: main.c:31
static HRESULT WINAPI ClassFactory_CreateInstance(IClassFactory *iface, IUnknown *pUnkOuter, REFIID riid, void **ppvObject)
Definition: main.c:255
static void process_detach(void)
Definition: main.c:94
HDC get_display_dc(void)
Definition: main.c:173
const char nsCycleCollectionTraversalCallback const char nsCycleCollectionTraversalCallback *static HINSTANCE shdoclc
Definition: main.c:40
static void free_strings(void)
Definition: main.c:87
HRESULT(* CreateInstanceFunc)(IUnknown *, REFIID, void **)
Definition: main.c:208
void WINAPI PrintHTML(HWND hwnd, HINSTANCE handle, LPCSTR cmdline, INT show)
Definition: main.c:380
static HDC display_dc
Definition: main.c:41
HINSTANCE get_shdoclc(void)
Definition: main.c:162
static HRESULT register_server(BOOL do_register)
Definition: main.c:419
#define IDS_STATUS_LAST
Definition: resource.h:26
#define IDS_STATUS_FIRST
Definition: resource.h:23
HRESULT WINAPI DECLSPEC_HOTPATCH CoCreateInstance(REFCLSID rclsid, LPUNKNOWN pUnkOuter, DWORD dwClsContext, REFIID iid, LPVOID *ppv)
Definition: compobj.c:3325
HRESULT WINAPI LoadTypeLibEx(LPCOLESTR szFile, REGKIND regkind, ITypeLib **pptLib)
Definition: typelib.c:473
HRESULT WINAPI UnRegisterTypeLib(REFGUID libid, WORD wVerMajor, WORD wVerMinor, LCID lcid, SYSKIND syskind)
Definition: typelib.c:882
r reserved
Definition: btrfs.c:3006
HINSTANCE hInst
Definition: dxdiag.c:13
unsigned int BOOL
Definition: ntddk_ex.h:94
unsigned long DWORD
Definition: ntddk_ex.h:95
pKey DeleteObject()
GLuint index
Definition: glext.h:6031
GLenum GLuint GLenum GLsizei const GLchar * buf
Definition: glext.h:7751
GLfloat GLfloat p
Definition: glext.h:8902
GLenum GLsizei len
Definition: glext.h:6722
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
HRESULT(* fnCreateInstance)(IUnknown *pUnkOuter, LPVOID *ppObj)
Definition: hnetcfg.c:37
#define TID_LIST
Definition: ieframe.h:306
REFIID riid
Definition: atlbase.h:39
REFIID LPVOID * ppv
Definition: atlbase.h:39
#define InterlockedCompareExchangePointer
Definition: interlocked.h:129
#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_a
Definition: kernel32.h:31
#define debugstr_w
Definition: kernel32.h:32
HRESULT HTMLLoadOptions_Create(IUnknown *pUnkOuter, REFIID riid, void **ppv)
Definition: loadopts.c:173
#define sprintf(buf, format,...)
Definition: sprintf.c:55
HDC hdc
Definition: main.c:9
static HINSTANCE hinst
Definition: edit.c:551
static HDC
Definition: imagelist.c:92
const IID IID_IObjectWithSite
static const WCHAR displayW[]
Definition: icm.c:30
HRESULT hres
Definition: protocol.c:465
static const WCHAR sp[]
Definition: suminfo.c:287
CLSID CLSID_AboutProtocol
void close_gecko(void) DECLSPEC_HIDDEN
Definition: nsembed.c:1076
thread_data_t * get_thread_data(BOOL) DECLSPEC_HIDDEN
Definition: task.c:352
struct nsCycleCollectionTraversalCallback nsCycleCollectionTraversalCallback
HRESULT ProtocolFactory_Create(REFCLSID, REFIID, void **) DECLSPEC_HIDDEN
Definition: protocol.c:1038
BOOL load_gecko(void) DECLSPEC_HIDDEN
Definition: nsembed.c:742
unsigned int UINT
Definition: ndis.h:50
#define LOCALE_SYSTEM_DEFAULT
@ REGKIND_REGISTER
Definition: oleauto.h:926
const GUID IID_IOleInPlaceActiveObject
const GUID IID_IViewObject
const GUID IID_IOleContainer
const GUID IID_IEnumConnections
const GUID IID_IConnectionPointContainer
const GUID IID_IConnectionPoint
const GUID IID_IPropertyNotifySink
const GUID IID_IProvideClassInfo
const GUID IID_IOleInPlaceFrame
const GUID IID_IOleWindow
const GUID IID_IViewObject2
const GUID IID_IDispatch
const GUID IID_IOleInPlaceObject
const GUID IID_IOleObject
const GUID IID_IOleInPlaceUIWindow
const GUID IID_IOleControl
const GUID IID_IPersistStreamInit
const GUID IID_IPersistFile
long LONG
Definition: pedump.c:60
const GUID IID_IPersist
Definition: proxy.cpp:14
#define DEFINE_GUID(name, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8)
Definition: guiddef.h:68
#define IsEqualGUID(rguid1, rguid2)
Definition: guiddef.h:147
#define REFIID
Definition: guiddef.h:118
#define REFCLSID
Definition: guiddef.h:117
#define snprintfW
Definition: unicode.h:66
HRESULT __wine_unregister_resources(HMODULE module) DECLSPEC_HIDDEN
Definition: register.c:110
HRESULT __wine_register_resources(HMODULE module) DECLSPEC_HIDDEN
Definition: register.c:98
#define CP_UTF8
Definition: nls.h:20
#define TRACE(s)
Definition: solgame.cpp:4
TCHAR * cmdline
Definition: stretchblt.cpp:32
IClassFactory IClassFactory_iface
Definition: main.c:210
CreateInstanceFunc fnCreateInstance
Definition: main.c:212
LONG ref
Definition: main.c:211
IOleInPlaceFrame * frame
Definition: scsiwmi.h:51
LPSTR pszValue
Definition: advpub.h:83
DWORD cEntries
Definition: advpub.h:97
STRENTRYA * pse
Definition: advpub.h:98
Definition: send.c:48
int32_t INT
Definition: typedefs.h:58
#define CONTAINING_RECORD(address, type, field)
Definition: typedefs.h:260
uint32_t ULONG
Definition: typedefs.h:59
int ret
@ SYS_WIN32
Definition: widltypes.h:552
#define LOAD_LIBRARY_AS_DATAFILE
Definition: winbase.h:342
#define TLS_OUT_OF_INDEXES
Definition: winbase.h:549
_In_ void _In_ PCCERT_CONTEXT _In_opt_ LPFILETIME _In_ DWORD _In_ DWORD _Outptr_opt_ void ** ppvObject
Definition: wincrypt.h:6082
_In_ LONG _In_ HWND hwnd
Definition: winddi.h:4023
#define HRESULT
Definition: msvc.h:7
#define WINAPI
Definition: msvc.h:6
#define S_FALSE
Definition: winerror.h:2357
#define E_NOINTERFACE
Definition: winerror.h:2364
#define CLASS_E_CLASSNOTAVAILABLE
Definition: winerror.h:2663
HDC WINAPI CreateICW(_In_opt_ LPCWSTR, _In_opt_ LPCWSTR, _In_opt_ LPCWSTR, _In_opt_ const DEVMODEW *)
int WINAPI LoadStringW(_In_opt_ HINSTANCE hInstance, _In_ UINT uID, _Out_writes_to_(cchBufferMax, return+1) LPWSTR lpBuffer, _In_ int cchBufferMax)
BOOL WINAPI DestroyWindow(_In_ HWND)
const char * LPCSTR
Definition: xmlstorage.h:183
char * LPSTR
Definition: xmlstorage.h:182
__wchar_t WCHAR
Definition: xmlstorage.h:180
const WCHAR * LPCWSTR
Definition: xmlstorage.h:185