don't crash if editing of the cell wasn't started for whatever reason (patch 502692)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@14341 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin 2002-02-21 16:17:13 +00:00
parent bff4ec6360
commit 2f159c5849

View File

@ -5832,7 +5832,14 @@ void wxGrid::OnKeyDown( wxKeyEvent& event )
|| editor->IsAcceptedKey(event) )
{
EnableCellEditControl();
editor->StartingKey(event);
// the editor could be not shown for a variety of
// reasons (i.e. blocked by the app or whatever), so
// check if it really was created
if ( m_cellEditCtrlEnabled )
{
editor->StartingKey(event);
}
}
else
{