1
0
mirror of https://github.com/wine-mirror/wine synced 2024-07-08 20:06:18 +00:00

shdocvw: Convert coclass registration to the IRegistrar mechanism.

This commit is contained in:
Alexandre Julliard 2011-01-19 21:30:14 +01:00
parent 2afe205ebd
commit 8bb4bde1e5
5 changed files with 98 additions and 141 deletions

View File

@ -49,5 +49,6 @@ SVG_SRCS = \
ietoolbar.svg
IDL_TLB_SRCS = shdocvw_v1.idl
IDL_R_SRCS = shdocvw_v1.idl
@MAKE_DLL_RULES@

View File

@ -24,6 +24,7 @@
#include "shdocvw.h"
#include "winreg.h"
#include "advpub.h"
#include "rpcproxy.h"
#include "isguids.h"
#include "winver.h"
@ -202,11 +203,6 @@ static HRESULT reg_install(LPCSTR section, STRTABLEA *strtable)
return hres;
}
static const GUID CLSID_MicrosoftBrowserArchitecture =
{0xa5e46e3a, 0x8849, 0x11d1, {0x9d, 0x8c, 0x00, 0xc0, 0x4f, 0xc9, 0x9d, 0x61}};
static const GUID CLSID_MruLongList =
{0x53bd6b4e, 0x3780, 0x4693, {0xaf, 0xc3, 0x71, 0x61, 0xc2, 0xf3, 0xee, 0x9c}};
#define INF_SET_CLSID(clsid) \
do \
{ \
@ -219,26 +215,14 @@ static const GUID CLSID_MruLongList =
static HRESULT register_server(BOOL doregister)
{
STRTABLEA strtable;
STRENTRYA pse[15];
static CLSID const *clsids[15];
STRENTRYA pse[3];
static CLSID const *clsids[3];
unsigned int i = 0;
HRESULT hres;
INF_SET_CLSID(CUrlHistory);
INF_SET_CLSID(Internet);
INF_SET_CLSID(InternetExplorer);
INF_SET_CLSID(InternetShortcut);
INF_SET_CLSID(MicrosoftBrowserArchitecture);
INF_SET_CLSID(MruLongList);
INF_SET_CLSID(SearchAssistantOC);
INF_SET_CLSID(ShellNameSpace);
INF_SET_CLSID(ShellSearchAssistantOC);
INF_SET_CLSID(ShellShellNameSpace);
INF_SET_CLSID(ShellUIHelper);
INF_SET_CLSID(ShellWindows);
INF_SET_CLSID(TaskbarList);
INF_SET_CLSID(WebBrowser);
INF_SET_CLSID(WebBrowser_V1);
for(i = 0; i < sizeof(pse)/sizeof(pse[0]); i++) {
pse[i].pszValue = HeapAlloc(GetProcessHeap(), 0, 39);
@ -266,24 +250,13 @@ static HRESULT register_server(BOOL doregister)
*/
HRESULT WINAPI DllRegisterServer(void)
{
ITypeLib *typelib;
HRESULT hres;
static const WCHAR shdocvwW[] = {'s','h','d','o','c','v','w','.','d','l','l',0};
hres = register_server(TRUE);
hres = __wine_register_resources( shdocvw_hinstance, NULL );
if(FAILED(hres))
return hres;
hres = LoadTypeLibEx(shdocvwW, REGKIND_REGISTER, &typelib);
if(FAILED(hres)) {
ERR("Could not load typelib: %08x\n", hres);
return hres;
}
ITypeLib_Release(typelib);
return hres;
return register_server(TRUE);
}
/***********************************************************************
@ -297,7 +270,7 @@ HRESULT WINAPI DllUnregisterServer(void)
if(FAILED(hres))
return hres;
return UnRegisterTypeLib(&LIBID_SHDocVw, 1, 1, LOCALE_SYSTEM_DEFAULT, SYS_WIN32);
return __wine_unregister_resources( shdocvw_hinstance, NULL );
}
static BOOL check_native_ie(void)

View File

@ -23,113 +23,22 @@ HKCR,"CLSID\%CLSID_InternetExplorer%",,,"Internet Explorer(Ver 1.0)"
HKCR,"CLSID\%CLSID_InternetExplorer%\LocalServer32",,,"""%16422%\Internet Explorer\iexplore.exe"""
HKCR,"CLSID\%CLSID_InternetExplorer%\ProgID",,,"InternetExplorer.Application.1"
HKCR,"CLSID\%CLSID_InternetExplorer%\VersionIndependentProgID",,,"InternetExplorer.Application"
HKCR,"InternetExplorer.Application",,,"Internet Explorer(Ver 1.0)"
HKCR,"InternetExplorer.Application\CLSID",,,"%CLSID_InternetExplorer%"
HKCR,"InternetExplorer.Application\CurVer",,,"InternetExplorer.Application.1"
HKCR,"InternetExplorer.Application.1",,,"Internet Explorer(Ver 1.0)"
HKCR,"InternetExplorer.Application.1\CLSID",,,"%CLSID_InternetExplorer%"
HKCR,"CLSID\%CLSID_SearchAssistantOC%",,,"SearchAssistantOC"
HKCR,"CLSID\%CLSID_SearchAssistantOC%\InProcServer32",,,"%MODULE%"
HKCR,"CLSID\%CLSID_SearchAssistantOC%\InProcServer32","ThreadingModel",,"Apartment"
HKCR,"CLSID\%CLSID_SearchAssistantOC%\ProgID",,,"SearchAssistantOC.SearchAssistantOC.1"
HKCR,"CLSID\%CLSID_SearchAssistantOC%\VersionIndependentProgID",,,"SearchAssistantOC.SearchAssistantOC"
HKCR,"SearchAssistantOC.SearchAssistantOC",,,"SearchAssistantOC"
HKCR,"SearchAssistantOC.SearchAssistantOC\CLSID",,,"%CLSID_SearchAssistantOC%"
HKCR,"SearchAssistantOC.SearchAssistantOC\CurVer",,,"SearchAssistantOC.SearchAssistantOC.1"
HKCR,"SearchAssistantOC.SearchAssistantOC.1",,,"SearchAssistantOC"
HKCR,"SearchAssistantOC.SearchAssistantOC.1\CLSID",,,"%CLSID_SearchAssistantOC%"
HKCR,"CLSID\%CLSID_ShellNameSpace%",,,"Shell Name Space"
HKCR,"CLSID\%CLSID_ShellNameSpace%\InProcServer32",,,"%MODULE%"
HKCR,"CLSID\%CLSID_ShellNameSpace%\InProcServer32","ThreadingModel",,"Apartment"
HKCR,"CLSID\%CLSID_ShellNameSpace%\ProgID",,,"ShellNameSpace.ShellNameSpace.1"
HKCR,"CLSID\%CLSID_ShellNameSpace%\VersionIndependentProgID",,,"ShellNameSpace.ShellNameSpace"
HKCR,"CLSID\%CLSID_CUrlHistory%",,,"Microsoft Url History Service"
HKCR,"CLSID\%CLSID_CUrlHistory%\InProcServer32",,,"%MODULE%"
HKCR,"CLSID\%CLSID_CUrlHistory%\InProcServer32","ThreadingModel",,"Apartment"
HKCR,"CLSID\%CLSID_MruLongList%",,,"MruLongList"
HKCR,"CLSID\%CLSID_MruLongList%\InProcServer32",,,"%MODULE%"
HKCR,"CLSID\%CLSID_MruLongList%\InProcServer32","ThreadingModel",,"Apartment"
HKCR,"CLSID\%CLSID_ShellShellNameSpace%",,,"Shell Name Space"
HKCR,"CLSID\%CLSID_ShellShellNameSpace%\InProcServer32",,,"%MODULE%"
HKCR,"CLSID\%CLSID_ShellShellNameSpace%\InProcServer32","ThreadingModel",,"Apartment"
HKCR,"CLSID\%CLSID_ShellShellNameSpace%\ProgID",,,"ShellNameSpace.ShellNameSpace.1"
HKCR,"CLSID\%CLSID_ShellShellNameSpace%\VersionIndependentProgID",,,"ShellNameSpace.ShellNameSpace"
HKCR,"CLSID\%CLSID_ShellUIHelper%",,,"Microsoft Shell UI Helper"
HKCR,"CLSID\%CLSID_ShellUIHelper%\InProcServer32",,,"%MODULE%"
HKCR,"CLSID\%CLSID_ShellUIHelper%\InProcServer32","ThreadingModel",,"Apartment"
HKCR,"CLSID\%CLSID_ShellUIHelper%\ProgID",,,"Shell.UIHelper.1"
HKCR,"Shell.UIHelper",,,"Microsoft Shell UI Helper"
HKCR,"Shell.UIHelper\CLSID",,,"%CLSID_ShellUIHelper%"
HKCR,"Shell.UIHelper\CurVer",,,"Shell.UIHelper.2"
HKCR,"Shell.UIHelper.1",,,"Microsoft Shell UI Helper"
HKCR,"Shell.UIHelper.1\CLSID",,,"%CLSID_ShellUIHelper%"
HKCR,"CLSID\%CLSID_Internet%\DefaultIcon",,,"shdoclc.dll,-190"
HKCR,"CLSID\%CLSID_Internet%\InProcServer32",,,"%MODULE%"
HKCR,"CLSID\%CLSID_Internet%\InProcServer32","ThreadingModel",,"Apartment"
HKCR,"CLSID\%CLSID_Internet%\Shell",,,"OpenHomePage"
HKCR,"CLSID\%CLSID_Internet%\Shell\OpenHomePage",,,"Open &Home Page"
HKCR,"CLSID\%CLSID_Internet%\Shell\OpenHomePage\Command",,,"""%16422%\Internet Explorer\iexplore.exe"""
HKCR,"CLSID\%CLSID_Internet%\ShellFolder",,2,"0x24"
HKCR,"CLSID\%CLSID_WebBrowser%",,,"Microsoft Web Browser"
HKCR,"CLSID\%CLSID_WebBrowser%\InProcServer32",,,"%MODULE%"
HKCR,"CLSID\%CLSID_WebBrowser%\InProcServer32","ThreadingModel",,"Apartment"
HKCR,"CLSID\%CLSID_WebBrowser%\ProgID",,,"Shell.Explorer.2"
HKCR,"CLSID\%CLSID_WebBrowser%\VersionIndependentProgID",,,"Shell.Explorer"
HKCR,"Shell.Explorer",,,"Microsoft Web Browser"
HKCR,"Shell.Explorer\CLSID",,,"%CLSID_WebBrowser%"
HKCR,"Shell.Explorer\CurVer",,,"Shell.Explorer.2"
HKCR,"Shell.Explorer.2",,,"Microsoft Web Browser"
HKCR,"Shell.Explorer.2\CLSID",,,"%CLSID_WebBrowser%"
HKCR,"CLSID\%CLSID_ShellWindows%",,,"ShellWindows"
HKCR,"CLSID\%CLSID_ShellWindows%\InProcServer32",,,"%MODULE%"
HKCR,"CLSID\%CLSID_ShellWindows%\InProcServer32","ThreadingModel",,"Apartment"
HKCR,"CLSID\%CLSID_MicrosoftBrowserArchitecture%",,,"Microsoft Browser Architecture"
HKCR,"CLSID\%CLSID_MicrosoftBrowserArchitecture%\InProcServer32",,,"%MODULE%"
HKCR,"CLSID\%CLSID_MicrosoftBrowserArchitecture%\InProcServer32","ThreadingModel",,"Apartment"
HKCR,"CLSID\%CLSID_ShellSearchAssistantOC%",,,"SearchAssistantOC"
HKCR,"CLSID\%CLSID_ShellSearchAssistantOC%\InProcServer32",,,"%MODULE%"
HKCR,"CLSID\%CLSID_ShellSearchAssistantOC%\InProcServer32","ThreadingModel",,"Apartment"
HKCR,"CLSID\%CLSID_ShellSearchAssistantOC%\ProgID",,,"SearchAssistantOC.SearchAssistantOC.1"
HKCR,"CLSID\%CLSID_ShellSearchAssistantOC%\VersionIndependentProgID",,,"SearchAssistantOC.SearchAssistantOC"
HKCR,"CLSID\%CLSID_WebBrowser_V1%",,,"Microsoft Web Browser Version 1"
HKCR,"CLSID\%CLSID_WebBrowser_V1%\InProcServer32",,,"%MODULE%"
HKCR,"CLSID\%CLSID_WebBrowser_V1%\InProcServer32","ThreadingModel",,"Apartment"
HKCR,"CLSID\%CLSID_WebBrowser_V1%\ProgID",,,"Shell.Explorer.1"
HKCR,"CLSID\%CLSID_WebBrowser_V1%\VersionIndependentProgID",,,"Shell.Explorer"
HKCR,"Shell.Explorer.1",,,"Microsoft Web Browser"
HKCR,"Shell.Explorer.1\CLSID",,,"%CLSID_WebBrowser_V1%"
HKCR,"CLSID\%CLSID_InternetShortcut%",,,"Internet Shortcut"
HKCR,"CLSID\%CLSID_InternetShortcut%\InProcServer32",,,"%MODULE%"
HKCR,"CLSID\%CLSID_InternetShortcut%\InProcServer32","ThreadingModel",,"Apartment"
HKCR,"CLSID\%CLSID_InternetShortcut%\ProgID",,,"InternetShortcut"
HKCR,"CLSID\%CLSID_InternetShortcut%\shellex\MayChangeDefaultMenu",,16
HKCR,"InternetShortcut",,,"Internet Shortcut"
HKCR,"InternetShortcut","EditFlags",2,"2"
HKCR,"InternetShortcut","IsShortcut",,
HKCR,"InternetShortcut","NeverShowExt",,
HKCR,"InternetShortcut\CLSID",,,"%CLSID_InternetShortcut%"
HKCR,"InternetShortcut\DefaultIcon",,,"url.dll,0"
HKCR,"InternetShortcut\shell\open\command",,,"rundll32.exe shdocvw.dll,OpenURL %l"
HKCR,"InternetShortcut\shell\print\command",,,"rundll32.exe mshtml.dll,PrintHTML ""%1"""
HKCR,"InternetShortcut\shell\printto\command",,,"rundll32.exe mshtml.dll,PrintHTML ""%1"" ""%2"" ""%3"" ""%4"""
HKCR,"CLSID\%CLSID_TaskbarList%",,,"Task Bar Communication"
HKCR,"CLSID\%CLSID_TaskbarList%\InProcServer32",,,"%MODULE%"
HKCR,"CLSID\%CLSID_TaskbarList%\InProcServer32","ThreadingModel",,"Apartment"
[URL.Reg]
HKLM,"Software\Microsoft\Windows\CurrentVersion\URL\DefaultPrefix",,,"http://"
HKLM,"Software\Microsoft\Windows\CurrentVersion\URL\Prefixes","ftp",,"ftp://"
@ -152,7 +61,3 @@ HKLM,"Software\Microsoft\Windows\CurrentVersion\App Paths\iexplore.exe","Path",,
HKLM,"Software\Microsoft\Internet Explorer","Build",,"86001"
HKLM,"Software\Microsoft\Internet Explorer","Version",,"8.0.6001.18702"
HKLM,"Software\Microsoft\Internet Explorer","W2kVersion",,"8.0.6001.18702"
[Strings]
MODULE="shdocvw.dll"

View File

@ -17,3 +17,44 @@
*/
#include "exdisp.idl"
[
threading(apartment),
uuid(53bd6b4e-3780-4693-afc3-7161c2f3ee9c)
] coclass MruLongList { }
[
helpstring("Microsoft Browser Architecture"),
threading(apartment),
uuid(a5e46e3a-8849-11d1-9d8c-00c04fc99d61)
] coclass MicrosoftBrowserArchitecture { }
[
threading(apartment),
uuid(871c5380-42a0-1069-a2ea-08002b30309d)
] coclass Internet { }
[
helpstring("Microsoft Url History Service"),
threading(apartment),
uuid(3c374a40-bae4-11cf-bf7d-00aa006946ee)
] coclass CUrlHistory { interface IUrlHistoryStg2; }
[
helpstring("Task Bar Communication"),
threading(apartment),
uuid(56fdf344-fd6d-11d0-958a-006097c9a090)
] coclass TaskbarList { interface ITaskbarList; }
[
helpstring("Internet Shortcut"),
threading(apartment),
progid("InternetShortcut"),
uuid(fbf23b40-e3f0-101b-8488-00aa003e56f8)
] coclass InternetShortcut
{
interface IUniformResourceLocatorA;
interface IUniformResourceLocatorW;
interface IPersistFile;
interface IPropertySetStorage;
}

View File

@ -26,6 +26,12 @@ import "docobj.idl";
#include <olectl.h>
#include <exdispid.h>
#ifndef __WIDL__
#define threading(model)
#define progid(str)
#define vi_progid(str)
#endif
cpp_quote("#ifdef WINE_NO_UNICODE_MACROS")
cpp_quote("#undef FindText")
cpp_quote("#endif")
@ -473,6 +479,10 @@ dispinterface DWebBrowserEvents2
}
[
helpstring("Microsoft Web Browser Version 1"),
threading(apartment),
progid("Shell.Explorer.1"),
vi_progid("Shell.Explorer"),
uuid(eab22ac3-30c1-11cf-a7eb-0000c05bae0b),
control
]
@ -485,6 +495,10 @@ coclass WebBrowser_V1
}
[
helpstring("Microsoft Web Browser"),
threading(apartment),
progid("Shell.Explorer.2"),
vi_progid("Shell.Explorer"),
uuid(8856f961-340a-11d0-a96b-00c04fd705a2),
control
]
@ -497,6 +511,9 @@ coclass WebBrowser
}
[
helpstring("Internet Explorer(Ver 1.0)"),
progid("InternetExplorer.Application.1"),
vi_progid("InternetExplorer.Application"),
uuid(0002df01-0000-0000-c000-000000000046)
]
coclass InternetExplorer
@ -599,6 +616,7 @@ interface IShellWindows : IDispatch
}
[
threading(apartment),
uuid(9ba05972-f6a8-11cf-a442-00a0c90a8f39)
]
coclass ShellWindows
@ -720,6 +738,10 @@ interface IShellUIHelper2 : IShellUIHelper {
}
[
helpstring("Microsoft Shell UI Helper"),
threading(apartment),
progid("Shell.UIHelper.1"),
vi_progid("Shell.UIHelper"),
uuid(64ab4bb7-111e-11d1-8f79-00c04fc2fbe1)
]
coclass ShellUIHelper {
@ -810,17 +832,25 @@ interface IShellNameSpace : IShellFavoritesNameSpace {
}
[
uuid(55136805-b2de-11d1-b9f2-00a0c98bc547)
helpstring("Shell Name Space"),
threading(apartment),
progid("ShellNameSpace.ShellNameSpace.1"),
vi_progid("ShellNameSpace.ShellNameSpace"),
uuid(2f2f1f96-2bc1-4b1c-be28-ea3774f4676a)
]
coclass ShellNameSpace {
coclass ShellShellNameSpace {
[default] interface IShellNameSpace;
[default, source] dispinterface DShellNameSpaceEvents;
}
[
uuid(2f2f1f96-2bc1-4b1c-be28-ea3774f4676a)
helpstring("Shell Name Space"),
threading(apartment),
progid("ShellNameSpace.ShellNameSpace.1"),
vi_progid("ShellNameSpace.ShellNameSpace"),
uuid(55136805-b2de-11d1-b9f2-00a0c98bc547)
]
coclass ShellShellNameSpace {
coclass ShellNameSpace {
[default] interface IShellNameSpace;
[default, source] dispinterface DShellNameSpaceEvents;
}
@ -989,15 +1019,10 @@ dispinterface _SearchAssistantEvents {
}
[
uuid(b45ff030-4447-11d2-85de-00C04fa35c89),
hidden
]
coclass SearchAssistantOC {
[default] interface ISearchAssistantOC3;
[default, source] dispinterface _SearchAssistantEvents;
}
[
helpstring("SearchAssistantOC"),
threading(apartment),
progid("SearchAssistantOC.SearchAssistantOC.1"),
vi_progid("SearchAssistantOC.SearchAssistantOC"),
uuid(2e71fd0f-aab1-42c0-9146-6d2c4edcf07d),
hidden
]
@ -1006,4 +1031,16 @@ coclass ShellSearchAssistantOC {
[default, source] dispinterface _SearchAssistantEvents;
}
[
threading(apartment),
progid("SearchAssistantOC.SearchAssistantOC.1"),
vi_progid("SearchAssistantOC.SearchAssistantOC"),
uuid(b45ff030-4447-11d2-85de-00C04fa35c89),
hidden
]
coclass SearchAssistantOC {
[default] interface ISearchAssistantOC3;
[default, source] dispinterface _SearchAssistantEvents;
}
} /* library */