mirror of
https://github.com/reactos/wine.git
synced 2024-11-28 22:20:26 +00:00
atl: AtlAxGetHost and AtlAxGetControl implementation.
This commit is contained in:
parent
26e6c13c43
commit
6ecdc5bbeb
@ -38,8 +38,8 @@
|
||||
44 stdcall AtlModuleExtractCreateWndData(ptr)
|
||||
45 stdcall AtlModuleRegisterWndClassInfoW(ptr ptr ptr)
|
||||
46 stub AtlModuleRegisterWndClassInfoA
|
||||
47 stub AtlAxGetControl
|
||||
48 stub AtlAxGetHost
|
||||
47 stdcall AtlAxGetControl(long ptr)
|
||||
48 stdcall AtlAxGetHost(long ptr)
|
||||
49 stub AtlRegisterClassCategoriesHelper
|
||||
50 stub AtlIPersistStreamInit_Load
|
||||
51 stub AtlIPersistStreamInit_Save
|
||||
|
@ -1261,3 +1261,47 @@ HWND WINAPI AtlAxCreateDialogW(HINSTANCE hInst, LPCWSTR name, HWND owner, DLGPRO
|
||||
FreeResource ( hrsrc );
|
||||
return res;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* AtlAxGetHost [ATL.@]
|
||||
*
|
||||
*/
|
||||
HRESULT WINAPI AtlAxGetHost(HWND hWnd, IUnknown **pUnk)
|
||||
{
|
||||
IOCS *This;
|
||||
|
||||
TRACE( "(%p, %p)\n", hWnd, pUnk );
|
||||
|
||||
*pUnk = NULL;
|
||||
|
||||
This = (IOCS*) GetWindowLongPtrW( hWnd, GWLP_USERDATA );
|
||||
if ( !This )
|
||||
{
|
||||
WARN("No container attached to %p\n", hWnd );
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
return IOCS_QueryInterface( This, &IID_IUnknown, (void**) pUnk );
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* AtlAxGetControl [ATL.@]
|
||||
*
|
||||
*/
|
||||
HRESULT WINAPI AtlAxGetControl(HWND hWnd, IUnknown **pUnk)
|
||||
{
|
||||
IOCS *This;
|
||||
|
||||
TRACE( "(%p, %p)\n", hWnd, pUnk );
|
||||
|
||||
*pUnk = NULL;
|
||||
|
||||
This = (IOCS*) GetWindowLongPtrW( hWnd, GWLP_USERDATA );
|
||||
if ( !This || !This->control )
|
||||
{
|
||||
WARN("No control attached to %p\n", hWnd );
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
return IOleObject_QueryInterface( This->control, &IID_IUnknown, (void**) pUnk );
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user