- Implement NtUserGetComboBoxInfo and use it in GetComboBoxInfo.

- Use Shared locks.

svn path=/trunk/; revision=29849
This commit is contained in:
James Tabor
2007-10-24 11:19:30 +00:00
parent 5bce4dda0c
commit 5005dede1c
3 changed files with 47 additions and 12 deletions
@@ -2375,5 +2375,9 @@ BOOL WINAPI GetComboBoxInfo(HWND hwndCombo, /* [in] handle to combo box */
PCOMBOBOXINFO pcbi /* [in/out] combo box information */)
{
TRACE("(%p, %p)\n", hwndCombo, pcbi);
#ifndef __REACTOS__
return SendMessageW(hwndCombo, CB_GETCOMBOBOXINFO, 0, (LPARAM)pcbi);
#else
return NtUserGetComboBoxInfo(hwndCombo, pcbi);
#endif
}
@@ -272,17 +272,6 @@ NtUserGetAltTabInfo(
return 0;
}
BOOL
STDCALL
NtUserGetComboBoxInfo(
HWND hWnd,
PCOMBOBOXINFO pcbi)
{
UNIMPLEMENTED
return 0;
}
DWORD
STDCALL
NtUserGetControlBrush(
@@ -2809,6 +2809,48 @@ CLEANUP:
}
BOOL
STDCALL
NtUserGetComboBoxInfo(
HWND hWnd,
PCOMBOBOXINFO pcbi)
{
PWINDOW_OBJECT Wnd;
DECLARE_RETURN(BOOL);
DPRINT("Enter NtUserGetComboBoxInfo\n");
UserEnterShared();
if (!(Wnd = UserGetWindowObject(hWnd)))
{
RETURN( FALSE );
}
_SEH_TRY
{
if(pcbi)
{
ProbeForWrite(pcbi,
sizeof(COMBOBOXINFO),
1);
}
}
_SEH_HANDLE
{
SetLastNtError(_SEH_GetExceptionCode());
_SEH_YIELD(RETURN(FALSE));
}
_SEH_END;
// Pass the user pointer, it was already probed.
RETURN( (BOOL) co_IntSendMessage( Wnd->hSelf, CB_GETCOMBOBOXINFO, 0, (LPARAM)pcbi));
CLEANUP:
DPRINT("Leave NtUserGetComboBoxInfo, ret=%i\n",_ret_);
UserLeave();
END_CLEANUP;
}
/*
* @implemented
*/
@@ -2882,7 +2924,7 @@ NtUserGetListBoxInfo(
DECLARE_RETURN(DWORD);
DPRINT("Enter NtUserGetListBoxInfo\n");
UserEnterExclusive();
UserEnterShared();
if (!(Wnd = UserGetWindowObject(hWnd)))
{