fix for generating set/kill focus events for wxRadioBox (also fixes TABbing in a panel containing a radio box)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@23709 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin 2003-09-19 12:06:18 +00:00
parent df0787b662
commit 1dab049c9e

View File

@ -996,6 +996,25 @@ LRESULT APIENTRY _EXPORT wxRadioBtnWndProc(HWND hwnd,
}
break;
case WM_SETFOCUS:
case WM_KILLFOCUS:
{
wxRadioBox *radiobox = (wxRadioBox *)
::GetWindowLong(hwnd, GWL_USERDATA);
wxCHECK_MSG( radiobox, 0, wxT("radio button without radio box?") );
// if we don't do this, no focus events are generated for the
// radiobox and, besides, we need to notify the parent about
// the focus change, otherwise the focus handling logic in
// wxControlContainer doesn't work
if ( message == WM_SETFOCUS )
radiobox->HandleSetFocus((WXHWND)wParam);
else
radiobox->HandleKillFocus((WXHWND)wParam);
}
break;
#ifdef __WIN32__
case WM_HELP:
{