diff --git a/src/generic/grid.cpp b/src/generic/grid.cpp index 78e502fc75..66b281a033 100644 --- a/src/generic/grid.cpp +++ b/src/generic/grid.cpp @@ -3758,6 +3758,9 @@ void wxGridWindow::ScrollWindow( int dx, int dy, const wxRect *rect ) void wxGridWindow::OnMouseEvent( wxMouseEvent& event ) { + if (event.ButtonDown(wxMOUSE_BTN_LEFT) && FindFocus() != this) + SetFocus(); + m_owner->ProcessGridCellMouseEvent( event ); }