oleaut32: Use the appropriate PSFactoryBuffer guid when registering interfaces.

This commit is contained in:
Alexandre Julliard 2009-09-23 14:32:01 +02:00
parent 6e2babc977
commit 9cb140c43d
3 changed files with 15 additions and 55 deletions

View File

@ -7,7 +7,8 @@ IMPORTLIB = oleaut32
IMPORTS = uuid ole32 rpcrt4 user32 gdi32 advapi32 kernel32 ntdll
DELAYIMPORTS = comctl32 urlmon windowscodecs
EXTRADEFS = -D_OLEAUT32_ -DCOM_NO_WINDOWS_H \
-DENTRY_PREFIX=OLEAUTPS_ -DPROXY_CLSID=CLSID_PSDispatch -DPROXY_DELEGATION -DREGISTER_PROXY_DLL
-DENTRY_PREFIX=OLEAUTPS_ -DPROXY_DELEGATION -DREGISTER_PROXY_DLL \
-DPROXY_CLSID_IS="{0xb196b286,0xbab4,0x101a,{0xb6,0x9c,0x00,0xaa,0x00,0x34,0x1d,0x07}}"
C_SRCS = \
connpt.c \

View File

@ -696,6 +696,7 @@ HRESULT WINAPI OleTranslateColor(
extern HRESULT WINAPI OLEAUTPS_DllGetClassObject(REFCLSID, REFIID, LPVOID *) DECLSPEC_HIDDEN;
extern BOOL WINAPI OLEAUTPS_DllMain(HINSTANCE, DWORD, LPVOID) DECLSPEC_HIDDEN;
extern GUID const CLSID_PSFactoryBuffer DECLSPEC_HIDDEN;
extern void _get_STDFONT_CF(LPVOID *);
extern void _get_STDPIC_CF(LPVOID *);
@ -728,7 +729,7 @@ static HRESULT WINAPI PSDispatchFacBuf_CreateProxy(IPSFactoryBuffer *iface, IUnk
HRESULT hr;
if (IsEqualIID(riid, &IID_IDispatch))
hr = OLEAUTPS_DllGetClassObject(&CLSID_PSDispatch, &IID_IPSFactoryBuffer, (void **)&pPSFB);
hr = OLEAUTPS_DllGetClassObject(&CLSID_PSFactoryBuffer, &IID_IPSFactoryBuffer, (void **)&pPSFB);
else
hr = TMARSHAL_DllGetClassObject(&CLSID_PSOAInterface, &IID_IPSFactoryBuffer, (void **)&pPSFB);
@ -746,7 +747,7 @@ static HRESULT WINAPI PSDispatchFacBuf_CreateStub(IPSFactoryBuffer *iface, REFII
HRESULT hr;
if (IsEqualIID(riid, &IID_IDispatch))
hr = OLEAUTPS_DllGetClassObject(&CLSID_PSDispatch, &IID_IPSFactoryBuffer, (void **)&pPSFB);
hr = OLEAUTPS_DllGetClassObject(&CLSID_PSFactoryBuffer, &IID_IPSFactoryBuffer, (void **)&pPSFB);
else
hr = TMARSHAL_DllGetClassObject(&CLSID_PSOAInterface, &IID_IPSFactoryBuffer, (void **)&pPSFB);
@ -790,11 +791,6 @@ HRESULT WINAPI DllGetClassObject(REFCLSID rclsid, REFIID iid, LPVOID *ppv)
return S_OK;
}
}
if (IsEqualCLSID(rclsid, &CLSID_PSTypeInfo) ||
IsEqualCLSID(rclsid, &CLSID_PSTypeLib) ||
IsEqualCLSID(rclsid, &CLSID_PSEnumVariant)) {
return OLEAUTPS_DllGetClassObject(&CLSID_PSDispatch, iid, ppv);
}
if (IsEqualCLSID(rclsid, &CLSID_PSDispatch) && IsEqualIID(iid, &IID_IPSFactoryBuffer)) {
*ppv = &pPSDispatchFacBuf;
IPSFactoryBuffer_AddRef((IPSFactoryBuffer *)*ppv);
@ -805,6 +801,12 @@ HRESULT WINAPI DllGetClassObject(REFCLSID rclsid, REFIID iid, LPVOID *ppv)
return S_OK;
/*FALLTHROUGH*/
}
if (IsEqualCLSID(rclsid, &CLSID_PSTypeInfo) ||
IsEqualCLSID(rclsid, &CLSID_PSTypeLib) ||
IsEqualCLSID(rclsid, &CLSID_PSDispatch) ||
IsEqualCLSID(rclsid, &CLSID_PSEnumVariant))
return OLEAUTPS_DllGetClassObject(&CLSID_PSFactoryBuffer, iid, ppv);
return OLEAUTPS_DllGetClassObject(rclsid, iid, ppv);
}

View File

@ -413,9 +413,6 @@ static GUID const CLSID_RecordInfo = {
static GUID const CLSID_OldFont = {
0x46763EE0, 0xCAB2, 0x11CE, {0x8C,0x20,0x00,0xAA,0x00,0x51,0xE5,0xD4} };
static GUID const CLSID_PSFactoryBuffer = {
0xB196B286, 0xBAB4, 0x101A, {0xB6,0x9C,0x00,0xAA,0x00,0x34,0x1D,0x07} };
static struct regsvr_coclass const coclass_list[] = {
{ &CLSID_RecordInfo,
"CLSID_RecordInfo",
@ -483,12 +480,6 @@ static struct regsvr_coclass const coclass_list[] = {
"Obsolete Font",
"OldFont"
},
{ &CLSID_PSFactoryBuffer,
"PSFactoryBuffer",
NULL,
"oleaut32.dll",
"Both"
},
{ NULL } /* list terminator */
};
@ -497,7 +488,6 @@ static struct regsvr_coclass const coclass_list[] = {
*/
#define INTERFACE_ENTRY(interface, clsid16, clsid32) { &IID_##interface, #interface, NULL, sizeof(interface##Vtbl)/sizeof(void*), clsid16, clsid32 }
#define LCL_INTERFACE_ENTRY(interface) INTERFACE_ENTRY(interface, NULL, NULL)
#define PSFAC_INTERFACE_ENTRY(interface) INTERFACE_ENTRY(interface, NULL, &CLSID_PSFactoryBuffer)
#define CLSID_INTERFACE_ENTRY(interface,clsid) INTERFACE_ENTRY(interface, clsid, clsid)
static struct regsvr_interface const interface_list[] = {
@ -508,43 +498,10 @@ static struct regsvr_interface const interface_list[] = {
CLSID_INTERFACE_ENTRY(ITypeComp,&CLSID_PSTypeComp),
CLSID_INTERFACE_ENTRY(ITypeInfo,&CLSID_PSTypeInfo),
CLSID_INTERFACE_ENTRY(ITypeLib,&CLSID_PSTypeLib),
PSFAC_INTERFACE_ENTRY(IAdviseSinkEx),
PSFAC_INTERFACE_ENTRY(IClassFactory2),
PSFAC_INTERFACE_ENTRY(IConnectionPoint),
PSFAC_INTERFACE_ENTRY(IConnectionPointContainer),
PSFAC_INTERFACE_ENTRY(ICreateErrorInfo),
PSFAC_INTERFACE_ENTRY(IEnumConnectionPoints),
PSFAC_INTERFACE_ENTRY(IEnumConnections),
PSFAC_INTERFACE_ENTRY(IEnumOleUndoUnits),
PSFAC_INTERFACE_ENTRY(IErrorInfo),
PSFAC_INTERFACE_ENTRY(IErrorLog),
PSFAC_INTERFACE_ENTRY(IFont),
PSFAC_INTERFACE_ENTRY(IObjectWithSite),
PSFAC_INTERFACE_ENTRY(IOleControl),
PSFAC_INTERFACE_ENTRY(IOleControlSite),
PSFAC_INTERFACE_ENTRY(IOleInPlaceSiteEx),
PSFAC_INTERFACE_ENTRY(IOleParentUndoUnit),
PSFAC_INTERFACE_ENTRY(IOleUndoManager),
PSFAC_INTERFACE_ENTRY(IOleUndoUnit),
PSFAC_INTERFACE_ENTRY(IPerPropertyBrowsing),
PSFAC_INTERFACE_ENTRY(IPersistMemory),
PSFAC_INTERFACE_ENTRY(IPersistPropertyBag),
PSFAC_INTERFACE_ENTRY(IPersistPropertyBag2),
PSFAC_INTERFACE_ENTRY(IPersistStreamInit),
PSFAC_INTERFACE_ENTRY(IPicture),
PSFAC_INTERFACE_ENTRY(IPointerInactive),
PSFAC_INTERFACE_ENTRY(IPropertyBag),
PSFAC_INTERFACE_ENTRY(IPropertyBag2),
PSFAC_INTERFACE_ENTRY(IPropertyNotifySink),
PSFAC_INTERFACE_ENTRY(IPropertyPage),
PSFAC_INTERFACE_ENTRY(IPropertyPage2),
PSFAC_INTERFACE_ENTRY(IPropertyPageSite),
PSFAC_INTERFACE_ENTRY(IProvideClassInfo),
PSFAC_INTERFACE_ENTRY(IProvideClassInfo2),
PSFAC_INTERFACE_ENTRY(IProvideMultipleClassInfo),
PSFAC_INTERFACE_ENTRY(IQuickActivate),
PSFAC_INTERFACE_ENTRY(ISimpleFrameSite),
PSFAC_INTERFACE_ENTRY(ISpecifyPropertyPages),
INTERFACE_ENTRY(ISupportErrorInfo,NULL,&CLSID_PSDispatch),
INTERFACE_ENTRY(ITypeFactory,NULL,&CLSID_PSDispatch),
INTERFACE_ENTRY(ITypeInfo2,NULL,&CLSID_PSDispatch),
INTERFACE_ENTRY(ITypeLib2,NULL,&CLSID_PSDispatch),
{ NULL } /* list terminator */
};