Commit 260cd4ec authored by Rein Klazes's avatar Rein Klazes Committed by Alexandre Julliard

First implementation of LoadTypeLibEx().

parent 97a99e51
......@@ -140,7 +140,7 @@ type win32
170 stdcall OaBuildVersion() OaBuildVersion
171 stub ClearCustData
180 stub CreateTypeLib2
183 stub LoadTypeLibEx
183 stdcall LoadTypeLibEx (ptr long ptr) LoadTypeLibEx
184 stub SystemTimeToVariantTime
185 stub VariantTimeToSystemTime
186 stdcall UnRegisterTypeLib (ptr long long long long) UnRegisterTypeLib
......
......@@ -162,11 +162,31 @@ HRESULT WINAPI LoadTypeLib(
OLECHAR *szFile, /* [in] Name of file to load from */
ITypeLib * *pptLib) /* [out] Pointer to pointer to loaded type library */
{
return LoadTypeLibEx(szFile, REGKIND_DEFAULT, pptLib);
}
/******************************************************************************
* LoadTypeLibEx [OLEAUT32.183]
* Loads and optionally registers a type library
*
* RETURNS
* Success: S_OK
* Failure: Status
*/
HRESULT WINAPI LoadTypeLibEx(
LPOLESTR szFile, /* [in] Name of file to load from */
REGKIND regkind, /* specify kind of registration */
ITypeLib **pptLib) /* [out] Pointer to pointer to loaded type library */
{
LPSTR p;
HRESULT res;
TRACE_(typelib)("('%s',%p)\n",debugstr_w(szFile),pptLib);
TRACE_(typelib)("('%s',%d,%p)\n",debugstr_w(szFile), regkind, pptLib);
p=HEAP_strdupWtoA(GetProcessHeap(),0,szFile);
if(regkind != REGKIND_NONE)
FIXME_(typelib) ("registration of typelibs not supported yet!\n");
res= TLB_ReadTypeLib(p, pptLib);
/* XXX need to free p ?? */
......
......@@ -495,4 +495,16 @@ typedef struct tagINTERFACEDATA {
UINT16 cMembers; /* count of members */
} INTERFACEDATA, * LPINTERFACEDATA;
typedef enum tagREGKIND
{
REGKIND_DEFAULT,
REGKIND_REGISTER,
REGKIND_NONE
} REGKIND;
HRESULT WINAPI LoadTypeLib(OLECHAR *szFile, ITypeLib **pptLib);
HRESULT WINAPI LoadTypeLibEx(LPOLESTR szFile, REGKIND regKind, ITypeLib **pptLib);
#endif /*__WINE_OLEAUTO_H*/
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment