TLW default item changes have changed Enter key processing: it was now handled as TAB even for controls such as wxTree/ListCtrl which need it themselves; fix this by checking for VK_RETURN in these classes MSWShouldPreProcessMessage() implementation; also removed specific test for wxTextCtrl in wxWindowMSW::MSWProcessMessage() and simplified its code

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@40405 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2006-07-31 22:06:24 +00:00
parent 955e46d25d
commit 90c6edd706
6 changed files with 66 additions and 53 deletions

View File

@@ -1763,6 +1763,20 @@ bool wxListCtrl::SortItems(wxListCtrlCompare fn, long data)
// message processing
// ----------------------------------------------------------------------------
bool wxListCtrl::MSWShouldPreProcessMessage(WXMSG* msg)
{
if ( msg->message == WM_KEYDOWN )
{
if ( msg->wParam == VK_RETURN )
{
// we need VK_RETURN to generate wxEVT_COMMAND_LIST_ITEM_ACTIVATED
return false;
}
}
return wxControl::MSWShouldPreProcessMessage(msg);
}
bool wxListCtrl::MSWCommand(WXUINT cmd, WXWORD id)
{
if (cmd == EN_UPDATE)