]> git.saurik.com Git - wxWidgets.git/commitdiff
Dont't finish any editing if there is no control
authorRobert Roebling <robert@roebling.de>
Thu, 16 Oct 2008 21:32:26 +0000 (21:32 +0000)
committerRobert Roebling <robert@roebling.de>
Thu, 16 Oct 2008 21:32:26 +0000 (21:32 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@56378 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/common/datavcmn.cpp

index 54cf95900200e4f586845440b207b7e76f4d156c..eaf672d2a572e30821228077cf453d61fbb93c75 100644 (file)
@@ -720,6 +720,8 @@ bool wxDataViewRendererBase::StartEditing( const wxDataViewItem &item, wxRect la
 
 void wxDataViewRendererBase::CancelEditing()
 {
+    if (!m_editorCtrl) return;
+    
     GetOwner()->GetOwner()->GetMainWindow()->SetFocus();
 
     m_editorCtrl->Hide();
@@ -728,6 +730,8 @@ void wxDataViewRendererBase::CancelEditing()
 
 bool wxDataViewRendererBase::FinishEditing()
 {
+    if (!m_editorCtrl) return true;
+
     wxVariant value;
     GetValueFromEditorCtrl( m_editorCtrl, value );