Don't activate items on Ctrl-M in generic wxListCtrl

This is unexpected, so add the check for the modifiers, as is done in
generic wxDataViewCtrl, to only accept the "real" Enter here and not
Ctrl-M sending the same key code.

Closes #17458.
This commit is contained in:
Vadim Zeitlin
2019-11-02 20:34:07 +01:00
parent 0dfafdcafb
commit 41eb39b4a7

View File

@@ -2994,6 +2994,12 @@ void wxListMainWindow::OnChar( wxKeyEvent &event )
case WXK_RETURN:
case WXK_EXECUTE:
if ( event.HasModifiers() )
{
event.Skip();
break;
}
SendNotify( m_current, wxEVT_LIST_ITEM_ACTIVATED );
break;