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:
@@ -1985,6 +1985,20 @@ void wxTreeCtrl::SortChildren(const wxTreeItemId& item)
|
||||
// implementation
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
bool wxTreeCtrl::MSWShouldPreProcessMessage(WXMSG* msg)
|
||||
{
|
||||
if ( msg->message == WM_KEYDOWN )
|
||||
{
|
||||
if ( msg->wParam == VK_RETURN )
|
||||
{
|
||||
// we need VK_RETURN to generate wxEVT_COMMAND_TREE_ITEM_ACTIVATED
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return wxTreeCtrlBase::MSWShouldPreProcessMessage(msg);
|
||||
}
|
||||
|
||||
bool wxTreeCtrl::MSWCommand(WXUINT cmd, WXWORD id)
|
||||
{
|
||||
if ( cmd == EN_UPDATE )
|
||||
|
Reference in New Issue
Block a user