Fixes #10247: wxDataViewCtrl - event is generated when clicking on a non existing row

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@57377 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robert Roebling
2008-12-16 21:57:40 +00:00
parent ddabd45b61
commit 5179bc0bca
3 changed files with 4 additions and 3 deletions

View File

@@ -2906,7 +2906,7 @@ void wxDataViewMainWindow::OnMouse( wxMouseEvent &event )
wxDataViewRenderer *cell = col->GetRenderer();
unsigned int current = GetLineAt( y );
if ((current > GetRowCount()) || (x > GetEndOfLastCol()))
if ((current >= GetRowCount()) || (x > GetEndOfLastCol()))
{
// Unselect all if below the last row ?
return;