X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/4cef387341f9876ba6496507e6a78cf8b0f6654e..9b49405777342458dc1666001865eef7309b6c30:/src/generic/datavgen.cpp?ds=inline diff --git a/src/generic/datavgen.cpp b/src/generic/datavgen.cpp index 73b8bbc920..afe948e080 100644 --- a/src/generic/datavgen.cpp +++ b/src/generic/datavgen.cpp @@ -3414,11 +3414,10 @@ void wxDataViewMainWindow::OnChar( wxKeyEvent &event ) switch ( event.GetKeyCode() ) { case WXK_RETURN: - { - if (m_currentRow >= 0) { wxWindow *parent = GetParent(); - wxDataViewEvent le(wxEVT_COMMAND_DATAVIEW_ITEM_ACTIVATED, parent->GetId()); + wxDataViewEvent le(wxEVT_COMMAND_DATAVIEW_ITEM_ACTIVATED, + parent->GetId()); le.SetItem( GetItemByRow(m_currentRow) ); le.SetEventObject(parent); le.SetModel(GetOwner()->GetModel()); @@ -3426,7 +3425,7 @@ void wxDataViewMainWindow::OnChar( wxKeyEvent &event ) parent->GetEventHandler()->ProcessEvent(le); } break; - } + case WXK_UP: if ( m_currentRow > 0 ) OnArrowChar( m_currentRow - 1, event );