]> git.saurik.com Git - wxWidgets.git/commitdiff
allow user code to override key handling in wxTreeCtrl
authorVadim Zeitlin <vadim@wxwidgets.org>
Mon, 20 Aug 2001 19:25:00 +0000 (19:25 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Mon, 20 Aug 2001 19:25:00 +0000 (19:25 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@11428 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/generic/treectlg.cpp

index 370cbab69530fa2818c8bf4556e6041fb877def9..4c72c6ac75d659dcb670cd27e74dc71575586145 100644 (file)
@@ -2183,7 +2183,11 @@ void wxGenericTreeCtrl::OnChar( wxKeyEvent &event )
     wxTreeEvent te( wxEVT_COMMAND_TREE_KEY_DOWN, GetId() );
     te.m_code = (int)event.KeyCode();
     te.SetEventObject( this );
-    GetEventHandler()->ProcessEvent( te );
+    if ( GetEventHandler()->ProcessEvent( te ) )
+    {
+        // intercepted by the user code
+        return;
+    }
 
     if ( (m_current == 0) || (m_key_current == 0) )
     {