Commit 44b76784 authored by Eric Pouech's avatar Eric Pouech Committed by Alexandre Julliard

atl: Enable compilation with long types.

parent e9c84cca
MODULE = atl.dll MODULE = atl.dll
IMPORTLIB = atl IMPORTLIB = atl
IMPORTS = uuid oleaut32 ole32 user32 gdi32 advapi32 shlwapi IMPORTS = uuid oleaut32 ole32 user32 gdi32 advapi32 shlwapi
EXTRADEFS = -DWINE_NO_LONG_TYPES -D_ATL_VER=_ATL_VER_30 EXTRADEFS = -D_ATL_VER=_ATL_VER_30
C_SRCS = \ C_SRCS = \
atl.c \ atl.c \
......
...@@ -70,7 +70,7 @@ HRESULT WINAPI AtlUnadvise(IUnknown *pUnkCP, const IID *iid, DWORD dw) ...@@ -70,7 +70,7 @@ HRESULT WINAPI AtlUnadvise(IUnknown *pUnkCP, const IID *iid, DWORD dw)
IConnectionPoint *cp; IConnectionPoint *cp;
HRESULT hres; HRESULT hres;
TRACE("%p %p %d\n", pUnkCP, iid, dw); TRACE("%p %p %ld\n", pUnkCP, iid, dw);
if(!pUnkCP) if(!pUnkCP)
return E_INVALIDARG; return E_INVALIDARG;
...@@ -210,7 +210,7 @@ HRESULT WINAPI AtlInternalQueryInterface(void* this, const _ATL_INTMAP_ENTRY* pE ...@@ -210,7 +210,7 @@ HRESULT WINAPI AtlInternalQueryInterface(void* this, const _ATL_INTMAP_ENTRY* pE
while (pEntries[i].pFunc != 0) while (pEntries[i].pFunc != 0)
{ {
TRACE("Trying entry %i (%s %lx %p)\n",i,debugstr_guid(pEntries[i].piid), TRACE("Trying entry %i (%s %Ix %p)\n",i,debugstr_guid(pEntries[i].piid),
pEntries[i].dw, pEntries[i].pFunc); pEntries[i].dw, pEntries[i].pFunc);
if (!pEntries[i].piid || IsEqualGUID(iid,pEntries[i].piid)) if (!pEntries[i].piid || IsEqualGUID(iid,pEntries[i].piid))
...@@ -233,7 +233,7 @@ HRESULT WINAPI AtlInternalQueryInterface(void* this, const _ATL_INTMAP_ENTRY* pE ...@@ -233,7 +233,7 @@ HRESULT WINAPI AtlInternalQueryInterface(void* this, const _ATL_INTMAP_ENTRY* pE
} }
i++; i++;
} }
TRACE("Done returning (0x%x)\n",rc); TRACE("Done returning (0x%lx)\n",rc);
return rc; return rc;
} }
...@@ -291,7 +291,7 @@ HRESULT WINAPI AtlModuleAddTermFunc(_ATL_MODULE *pM, _ATL_TERMFUNC *pFunc, DWORD ...@@ -291,7 +291,7 @@ HRESULT WINAPI AtlModuleAddTermFunc(_ATL_MODULE *pM, _ATL_TERMFUNC *pFunc, DWORD
{ {
_ATL_TERMFUNC_ELEM *termfunc_elem; _ATL_TERMFUNC_ELEM *termfunc_elem;
TRACE("version %04x (%p %p %ld)\n", _ATL_VER, pM, pFunc, dw); TRACE("version %04x (%p %p %Id)\n", _ATL_VER, pM, pFunc, dw);
if (_ATL_VER > _ATL_VER_30 || pM->cbSize > ATLVer1Size) { if (_ATL_VER > _ATL_VER_30 || pM->cbSize > ATLVer1Size) {
termfunc_elem = HeapAlloc(GetProcessHeap(), 0, sizeof(_ATL_TERMFUNC_ELEM)); termfunc_elem = HeapAlloc(GetProcessHeap(), 0, sizeof(_ATL_TERMFUNC_ELEM));
...@@ -488,7 +488,7 @@ HRESULT WINAPI AtlComModuleGetClassObject(_ATL_COM_MODULE *pm, REFCLSID rclsid, ...@@ -488,7 +488,7 @@ HRESULT WINAPI AtlComModuleGetClassObject(_ATL_COM_MODULE *pm, REFCLSID rclsid,
hres = (*iter)->pfnGetClassObject((*iter)->pfnCreateInstance, &IID_IUnknown, (void**)&(*iter)->pCF); hres = (*iter)->pfnGetClassObject((*iter)->pfnCreateInstance, &IID_IUnknown, (void**)&(*iter)->pCF);
if((*iter)->pCF) if((*iter)->pCF)
hres = IUnknown_QueryInterface((*iter)->pCF, riid, ppv); hres = IUnknown_QueryInterface((*iter)->pCF, riid, ppv);
TRACE("returning %p (%08x)\n", *ppv, hres); TRACE("returning %p (%08lx)\n", *ppv, hres);
return hres; return hres;
} }
} }
...@@ -513,7 +513,7 @@ HRESULT WINAPI AtlComModuleGetClassObject(_ATL_COM_MODULE *pm, REFCLSID rclsid, ...@@ -513,7 +513,7 @@ HRESULT WINAPI AtlComModuleGetClassObject(_ATL_COM_MODULE *pm, REFCLSID rclsid,
hres = (*iter)->pfnGetClassObject((*iter)->pfnCreateInstance, &IID_IUnknown, (void**)&(*iter)->pCache->pCF); hres = (*iter)->pfnGetClassObject((*iter)->pfnCreateInstance, &IID_IUnknown, (void**)&(*iter)->pCache->pCF);
if((*iter)->pCache->pCF) if((*iter)->pCache->pCF)
hres = IUnknown_QueryInterface((*iter)->pCache->pCF, riid, ppv); hres = IUnknown_QueryInterface((*iter)->pCache->pCF, riid, ppv);
TRACE("returning %p (%08x)\n", *ppv, hres); TRACE("returning %p (%08lx)\n", *ppv, hres);
return hres; return hres;
} }
} }
...@@ -533,7 +533,7 @@ HRESULT WINAPI AtlComModuleRegisterClassObjects(_ATL_COM_MODULE *module, DWORD c ...@@ -533,7 +533,7 @@ HRESULT WINAPI AtlComModuleRegisterClassObjects(_ATL_COM_MODULE *module, DWORD c
IUnknown *unk; IUnknown *unk;
HRESULT hres; HRESULT hres;
TRACE("(%p %x %x)\n", module, context, flags); TRACE("(%p %lx %lx)\n", module, context, flags);
if(!module) if(!module)
return E_INVALIDARG; return E_INVALIDARG;
...@@ -561,7 +561,7 @@ HRESULT WINAPI AtlComModuleRegisterClassObjects(_ATL_COM_MODULE *module, DWORD c ...@@ -561,7 +561,7 @@ HRESULT WINAPI AtlComModuleRegisterClassObjects(_ATL_COM_MODULE *module, DWORD c
IUnknown *unk; IUnknown *unk;
HRESULT hres; HRESULT hres;
TRACE("(%p %x %x)\n", module, context, flags); TRACE("(%p %lx %lx)\n", module, context, flags);
if(!module) if(!module)
return E_INVALIDARG; return E_INVALIDARG;
...@@ -964,7 +964,7 @@ DWORD WINAPI AtlGetVersion(void *pReserved) ...@@ -964,7 +964,7 @@ DWORD WINAPI AtlGetVersion(void *pReserved)
BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
{ {
TRACE("(0x%p, %d, %p)\n", hinstDLL, fdwReason, lpvReserved); TRACE("(0x%p, %ld, %p)\n", hinstDLL, fdwReason, lpvReserved);
switch(fdwReason) { switch(fdwReason) {
case DLL_PROCESS_ATTACH: case DLL_PROCESS_ATTACH:
......
...@@ -134,7 +134,7 @@ HRESULT WINAPI AtlModuleRegisterClassObjects(_ATL_MODULEW *pM, DWORD dwClsContex ...@@ -134,7 +134,7 @@ HRESULT WINAPI AtlModuleRegisterClassObjects(_ATL_MODULEW *pM, DWORD dwClsContex
_ATL_OBJMAP_ENTRYW_V1 *obj; _ATL_OBJMAP_ENTRYW_V1 *obj;
int i=0; int i=0;
TRACE("(%p %i %i)\n",pM, dwClsContext, dwFlags); TRACE("(%p %li %li)\n",pM, dwClsContext, dwFlags);
if (pM == NULL) if (pM == NULL)
return E_INVALIDARG; return E_INVALIDARG;
...@@ -155,7 +155,7 @@ HRESULT WINAPI AtlModuleRegisterClassObjects(_ATL_MODULEW *pM, DWORD dwClsContex ...@@ -155,7 +155,7 @@ HRESULT WINAPI AtlModuleRegisterClassObjects(_ATL_MODULEW *pM, DWORD dwClsContex
dwFlags, &obj->dwRegister); dwFlags, &obj->dwRegister);
if (FAILED (rc) ) if (FAILED (rc) )
WARN("Failed to register object %i: 0x%08x\n", i, rc); WARN("Failed to register object %i: 0x%08lx\n", i, rc);
if (pUnknown) if (pUnknown)
IUnknown_Release(pUnknown); IUnknown_Release(pUnknown);
......
...@@ -211,7 +211,7 @@ static ULONG WINAPI OleClientSite_AddRef(IOleClientSite *iface) ...@@ -211,7 +211,7 @@ static ULONG WINAPI OleClientSite_AddRef(IOleClientSite *iface)
{ {
IOCS *This = impl_from_IOleClientSite(iface); IOCS *This = impl_from_IOleClientSite(iface);
ULONG ref = InterlockedIncrement(&This->ref); ULONG ref = InterlockedIncrement(&This->ref);
TRACE("(%p)->(%d)\n", This, ref); TRACE("(%p)->(%ld)\n", This, ref);
return ref; return ref;
} }
...@@ -220,7 +220,7 @@ static ULONG WINAPI OleClientSite_Release(IOleClientSite *iface) ...@@ -220,7 +220,7 @@ static ULONG WINAPI OleClientSite_Release(IOleClientSite *iface)
IOCS *This = impl_from_IOleClientSite(iface); IOCS *This = impl_from_IOleClientSite(iface);
ULONG ref = InterlockedDecrement(&This->ref); ULONG ref = InterlockedDecrement(&This->ref);
TRACE("(%p)->(%d)\n", This, ref); TRACE("(%p)->(%ld)\n", This, ref);
if (!ref) if (!ref)
{ {
...@@ -242,7 +242,7 @@ static HRESULT WINAPI OleClientSite_GetMoniker(IOleClientSite *iface, DWORD dwAs ...@@ -242,7 +242,7 @@ static HRESULT WINAPI OleClientSite_GetMoniker(IOleClientSite *iface, DWORD dwAs
{ {
IOCS *This = impl_from_IOleClientSite(iface); IOCS *This = impl_from_IOleClientSite(iface);
FIXME( "(%p, 0x%x, 0x%x, %p)\n", This, dwAssign, dwWhichMoniker, ppmk ); FIXME( "(%p, 0x%lx, 0x%lx, %p)\n", This, dwAssign, dwWhichMoniker, ppmk );
return E_NOTIMPL; return E_NOTIMPL;
} }
...@@ -310,7 +310,7 @@ static HRESULT WINAPI OleContainer_ParseDisplayName(IOleContainer* iface, IBindC ...@@ -310,7 +310,7 @@ static HRESULT WINAPI OleContainer_ParseDisplayName(IOleContainer* iface, IBindC
static HRESULT WINAPI OleContainer_EnumObjects(IOleContainer* iface, DWORD grfFlags, IEnumUnknown** ppenum) static HRESULT WINAPI OleContainer_EnumObjects(IOleContainer* iface, DWORD grfFlags, IEnumUnknown** ppenum)
{ {
IOCS *This = impl_from_IOleContainer(iface); IOCS *This = impl_from_IOleContainer(iface);
FIXME( "(%p, %u, %p) - stub\n", This, grfFlags, ppenum ); FIXME( "(%p, %lu, %p) - stub\n", This, grfFlags, ppenum );
return E_NOTIMPL; return E_NOTIMPL;
} }
...@@ -1067,7 +1067,7 @@ HRESULT WINAPI AtlAxCreateControlLicEx(LPCOLESTR lpszName, HWND hWnd, ...@@ -1067,7 +1067,7 @@ HRESULT WINAPI AtlAxCreateControlLicEx(LPCOLESTR lpszName, HWND hWnd,
(void**) &pControl ); (void**) &pControl );
if ( FAILED( hRes ) ) if ( FAILED( hRes ) )
{ {
WARN( "cannot create ActiveX control %s instance - error 0x%08x\n", WARN( "cannot create ActiveX control %s instance - error 0x%08lx\n",
debugstr_guid( &controlId ), hRes ); debugstr_guid( &controlId ), hRes );
return hRes; return hRes;
} }
...@@ -1097,7 +1097,7 @@ HRESULT WINAPI AtlAxCreateControlLicEx(LPCOLESTR lpszName, HWND hWnd, ...@@ -1097,7 +1097,7 @@ HRESULT WINAPI AtlAxCreateControlLicEx(LPCOLESTR lpszName, HWND hWnd,
hRes = IOleObject_QueryInterface( pControl, &IID_IWebBrowser2, (void**) &browser ); hRes = IOleObject_QueryInterface( pControl, &IID_IWebBrowser2, (void**) &browser );
if ( !browser ) if ( !browser )
WARN( "Cannot query IWebBrowser2 interface: %08x\n", hRes ); WARN( "Cannot query IWebBrowser2 interface: %08lx\n", hRes );
else { else {
VARIANT url; VARIANT url;
...@@ -1108,7 +1108,7 @@ HRESULT WINAPI AtlAxCreateControlLicEx(LPCOLESTR lpszName, HWND hWnd, ...@@ -1108,7 +1108,7 @@ HRESULT WINAPI AtlAxCreateControlLicEx(LPCOLESTR lpszName, HWND hWnd,
hRes = IWebBrowser2_Navigate2( browser, &url, NULL, NULL, NULL, NULL ); hRes = IWebBrowser2_Navigate2( browser, &url, NULL, NULL, NULL, NULL );
if ( FAILED( hRes ) ) if ( FAILED( hRes ) )
WARN( "IWebBrowser2::Navigate2 failed: %08x\n", hRes ); WARN( "IWebBrowser2::Navigate2 failed: %08lx\n", hRes );
SysFreeString( V_BSTR(&url) ); SysFreeString( V_BSTR(&url) );
IWebBrowser2_Release( browser ); IWebBrowser2_Release( browser );
...@@ -1331,7 +1331,7 @@ HWND WINAPI AtlAxCreateDialogW(HINSTANCE hInst, LPCWSTR name, HWND owner, DLGPRO ...@@ -1331,7 +1331,7 @@ HWND WINAPI AtlAxCreateDialogW(HINSTANCE hInst, LPCWSTR name, HWND owner, DLGPRO
LPDLGTEMPLATEW newptr; LPDLGTEMPLATEW newptr;
HWND res; HWND res;
TRACE("(%p %s %p %p %lx)\n", hInst, debugstr_w(name), owner, dlgProc, param); TRACE("(%p %s %p %p %Ix)\n", hInst, debugstr_w(name), owner, dlgProc, param);
hrsrc = FindResourceW( hInst, name, (LPWSTR)RT_DIALOG ); hrsrc = FindResourceW( hInst, name, (LPWSTR)RT_DIALOG );
if ( !hrsrc ) if ( !hrsrc )
......
...@@ -233,7 +233,7 @@ static HRESULT do_process_key(LPCOLESTR *pstr, HKEY parent_key, strbuf *buf, BOO ...@@ -233,7 +233,7 @@ static HRESULT do_process_key(LPCOLESTR *pstr, HKEY parent_key, strbuf *buf, BOO
RegDeleteTreeW(parent_key, buf->str); RegDeleteTreeW(parent_key, buf->str);
lres = RegCreateKeyW(parent_key, buf->str, &hkey); lres = RegCreateKeyW(parent_key, buf->str, &hkey);
if(lres != ERROR_SUCCESS) { if(lres != ERROR_SUCCESS) {
WARN("Could not create(open) key: %08x\n", lres); WARN("Could not create(open) key: %08lx\n", lres);
hres = HRESULT_FROM_WIN32(lres); hres = HRESULT_FROM_WIN32(lres);
break; break;
} }
...@@ -242,7 +242,7 @@ static HRESULT do_process_key(LPCOLESTR *pstr, HKEY parent_key, strbuf *buf, BOO ...@@ -242,7 +242,7 @@ static HRESULT do_process_key(LPCOLESTR *pstr, HKEY parent_key, strbuf *buf, BOO
strbuf_write(buf->str, &name, -1); strbuf_write(buf->str, &name, -1);
lres = RegOpenKeyW(parent_key, buf->str, &hkey); lres = RegOpenKeyW(parent_key, buf->str, &hkey);
if(lres != ERROR_SUCCESS) if(lres != ERROR_SUCCESS)
WARN("Could not open key %s: %08x\n", debugstr_w(name.str), lres); WARN("Could not open key %s: %08lx\n", debugstr_w(name.str), lres);
} }
if(key_type != DO_DELETE && *iter == '=') { if(key_type != DO_DELETE && *iter == '=') {
...@@ -264,7 +264,7 @@ static HRESULT do_process_key(LPCOLESTR *pstr, HKEY parent_key, strbuf *buf, BOO ...@@ -264,7 +264,7 @@ static HRESULT do_process_key(LPCOLESTR *pstr, HKEY parent_key, strbuf *buf, BOO
lres = RegSetValueExW(hkey, name.len ? name.str : NULL, 0, REG_SZ, (PBYTE)buf->str, lres = RegSetValueExW(hkey, name.len ? name.str : NULL, 0, REG_SZ, (PBYTE)buf->str,
(lstrlenW(buf->str)+1)*sizeof(WCHAR)); (lstrlenW(buf->str)+1)*sizeof(WCHAR));
if(lres != ERROR_SUCCESS) { if(lres != ERROR_SUCCESS) {
WARN("Could set value of key: %08x\n", lres); WARN("Could set value of key: %08lx\n", lres);
hres = HRESULT_FROM_WIN32(lres); hres = HRESULT_FROM_WIN32(lres);
break; break;
} }
...@@ -278,7 +278,7 @@ static HRESULT do_process_key(LPCOLESTR *pstr, HKEY parent_key, strbuf *buf, BOO ...@@ -278,7 +278,7 @@ static HRESULT do_process_key(LPCOLESTR *pstr, HKEY parent_key, strbuf *buf, BOO
lres = RegSetValueExW(hkey, name.len ? name.str : NULL, 0, REG_DWORD, lres = RegSetValueExW(hkey, name.len ? name.str : NULL, 0, REG_DWORD,
(PBYTE)&dw, sizeof(dw)); (PBYTE)&dw, sizeof(dw));
if(lres != ERROR_SUCCESS) { if(lres != ERROR_SUCCESS) {
WARN("Could set value of key: %08x\n", lres); WARN("Could set value of key: %08lx\n", lres);
hres = HRESULT_FROM_WIN32(lres); hres = HRESULT_FROM_WIN32(lres);
break; break;
} }
...@@ -309,7 +309,7 @@ static HRESULT do_process_key(LPCOLESTR *pstr, HKEY parent_key, strbuf *buf, BOO ...@@ -309,7 +309,7 @@ static HRESULT do_process_key(LPCOLESTR *pstr, HKEY parent_key, strbuf *buf, BOO
lres = RegSetValueExW(hkey, name.len ? name.str : NULL, 0, REG_BINARY, lres = RegSetValueExW(hkey, name.len ? name.str : NULL, 0, REG_BINARY,
bytes, count); bytes, count);
if(lres != ERROR_SUCCESS) { if(lres != ERROR_SUCCESS) {
WARN("Could not set value of key: 0x%08x\n", lres); WARN("Could not set value of key: 0x%08lx\n", lres);
hres = HRESULT_FROM_WIN32(lres); hres = HRESULT_FROM_WIN32(lres);
} }
} }
...@@ -404,7 +404,7 @@ static HRESULT do_process_root_key(LPCOLESTR data, BOOL do_register) ...@@ -404,7 +404,7 @@ static HRESULT do_process_root_key(LPCOLESTR data, BOOL do_register)
} }
hres = do_process_key(&iter, root_keys[i].key, &buf, do_register); hres = do_process_key(&iter, root_keys[i].key, &buf, do_register);
if(FAILED(hres)) { if(FAILED(hres)) {
WARN("Processing key failed: %08x\n", hres); WARN("Processing key failed: %08lx\n", hres);
break; break;
} }
hres = get_word(&iter, &buf); hres = get_word(&iter, &buf);
...@@ -533,7 +533,7 @@ static ULONG WINAPI Registrar_AddRef(IRegistrar *iface) ...@@ -533,7 +533,7 @@ static ULONG WINAPI Registrar_AddRef(IRegistrar *iface)
{ {
Registrar *This = impl_from_IRegistrar(iface); Registrar *This = impl_from_IRegistrar(iface);
ULONG ref = InterlockedIncrement(&This->ref); ULONG ref = InterlockedIncrement(&This->ref);
TRACE("(%p) ->%d\n", This, ref); TRACE("(%p) ->%ld\n", This, ref);
return ref; return ref;
} }
...@@ -542,7 +542,7 @@ static ULONG WINAPI Registrar_Release(IRegistrar *iface) ...@@ -542,7 +542,7 @@ static ULONG WINAPI Registrar_Release(IRegistrar *iface)
Registrar *This = impl_from_IRegistrar(iface); Registrar *This = impl_from_IRegistrar(iface);
ULONG ref = InterlockedDecrement(&This->ref); ULONG ref = InterlockedDecrement(&This->ref);
TRACE("(%p) ->%d\n", This, ref); TRACE("(%p) ->%ld\n", This, ref);
if(!ref) { if(!ref) {
IRegistrar_ClearReplacements(iface); IRegistrar_ClearReplacements(iface);
HeapFree(GetProcessHeap(), 0, This); HeapFree(GetProcessHeap(), 0, This);
......
MODULE = atl100.dll MODULE = atl100.dll
IMPORTLIB = atl100 IMPORTLIB = atl100
IMPORTS = uuid ole32 oleaut32 user32 gdi32 advapi32 shlwapi IMPORTS = uuid ole32 oleaut32 user32 gdi32 advapi32 shlwapi
EXTRADEFS = -DWINE_NO_LONG_TYPES -D_ATL_VER=_ATL_VER_100 EXTRADEFS = -D_ATL_VER=_ATL_VER_100
PARENTSRC = ../atl PARENTSRC = ../atl
C_SRCS = \ C_SRCS = \
......
MODULE = atl110.dll MODULE = atl110.dll
IMPORTS = oleaut32 ole32 user32 gdi32 advapi32 uuid shlwapi IMPORTS = oleaut32 ole32 user32 gdi32 advapi32 uuid shlwapi
EXTRADEFS = -DWINE_NO_LONG_TYPES -D_ATL_VER=_ATL_VER_110 EXTRADEFS = -D_ATL_VER=_ATL_VER_110
PARENTSRC = ../atl PARENTSRC = ../atl
C_SRCS = \ C_SRCS = \
......
MODULE = atl80.dll MODULE = atl80.dll
IMPORTLIB = atl80 IMPORTLIB = atl80
IMPORTS = oleaut32 user32 ole32 gdi32 advapi32 uuid shlwapi IMPORTS = oleaut32 user32 ole32 gdi32 advapi32 uuid shlwapi
EXTRADEFS = -DWINE_NO_LONG_TYPES -D_ATL_VER=_ATL_VER_80 EXTRADEFS = -D_ATL_VER=_ATL_VER_80
PARENTSRC = ../atl PARENTSRC = ../atl
C_SRCS = \ C_SRCS = \
......
MODULE = atl90.dll MODULE = atl90.dll
IMPORTS = oleaut32 user32 ole32 gdi32 advapi32 uuid shlwapi IMPORTS = oleaut32 user32 ole32 gdi32 advapi32 uuid shlwapi
EXTRADEFS = -DWINE_NO_LONG_TYPES -D_ATL_VER=_ATL_VER_90 EXTRADEFS = -D_ATL_VER=_ATL_VER_90
PARENTSRC = ../atl PARENTSRC = ../atl
C_SRCS = \ C_SRCS = \
......
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