From b718a533ac2c8406a786369b4eaa1c84f0039188 Mon Sep 17 00:00:00 2001 From: Jaakko Salli Date: Wed, 13 Apr 2011 16:39:06 +0000 Subject: [PATCH] wxEVT_COMMAND_TEXT_UPDATED events from wxComboCtrl's embedded wxTextCtrl kept confusing wxPropertyGrid::HandleCustomEditorEvent(). We need to ignore them. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67440 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/propgrid/propgrid.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/propgrid/propgrid.cpp b/src/propgrid/propgrid.cpp index 2b2877276d..863581ae76 100644 --- a/src/propgrid/propgrid.cpp +++ b/src/propgrid/propgrid.cpp @@ -3608,6 +3608,12 @@ bool wxPropertyGrid::HandleCustomEditorEvent( wxEvent &event ) } else if ( wnd->IsKindOf(CLASSINFO(wxComboCtrl)) ) { + // In some cases we might stumble unintentionally on + // wxComboCtrl's embedded wxTextCtrl's events. Let's + // avoid them. + if ( editorWnd->IsKindOf(CLASSINFO(wxTextCtrl)) ) + return false; + wxComboCtrl* cc = (wxComboCtrl*) wnd; wxString newTcValue = cc->GetTextCtrl()->GetValue();