Attempt at compile fix

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@62176 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart
2009-09-28 06:07:43 +00:00
parent ca5a36146e
commit 1690c2ce36

View File

@@ -438,11 +438,7 @@ bool wxComboBox::MSWShouldPreProcessMessage(WXMSG *pMsg)
WXHWND wxComboBox::GetEditHWNDIfAvailable() const
{
// notice that a slightly safer alternative could be to use FindWindowEx()
// but it's not available under WinCE so just take the first child for now
// to keep one version of the code for all platforms and fix it later if
// problems are discovered
#if defined(WINVER) && WINVER >= 0x0500
typedef BOOL (WINAPI *GetComboBoxInfo_t)(HWND, COMBOBOXINFO*);
static GetComboBoxInfo_t s_pfnGetComboBoxInfo = NULL;
static bool s_triedToLoad = false;
@@ -459,6 +455,7 @@ WXHWND wxComboBox::GetEditHWNDIfAvailable() const
(*s_pfnGetComboBoxInfo)(GetHwnd(), &info);
return info.hwndItem;
}
#endif
if (HasFlag(wxCB_SIMPLE))
{
@@ -467,6 +464,11 @@ WXHWND wxComboBox::GetEditHWNDIfAvailable() const
return (WXHWND) ::ChildWindowFromPoint(GetHwnd(), pt);
}
// notice that a slightly safer alternative could be to use FindWindowEx()
// but it's not available under WinCE so just take the first child for now
// to keep one version of the code for all platforms and fix it later if
// problems are discovered
// we assume that the only child of the combobox is the edit window
return (WXHWND)::GetWindow(GetHwnd(), GW_CHILD);
}