]> git.saurik.com Git - wxWidgets.git/commitdiff
Avoid default child window focus behavior in generic wxListCtrl. Fixes #9563
authorRobin Dunn <robin@alldunn.com>
Sun, 10 Aug 2008 00:26:53 +0000 (00:26 +0000)
committerRobin Dunn <robin@alldunn.com>
Sun, 10 Aug 2008 00:26:53 +0000 (00:26 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@55043 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/generic/listctrl.cpp

index 4486e729b2790ebfc6935b4dc65fb1ac248f41e6..0bdc1e54fd03d982337c881432540c3cdc29a94e 100644 (file)
@@ -615,6 +615,8 @@ public:
 
     void OnPaint( wxPaintEvent &event );
 
+    void OnChildFocus(wxChildFocusEvent& event);
+    
     void DrawImage( int index, wxDC *dc, int x, int y );
     void GetImageSize( int index, int &width, int &height ) const;
     int GetTextLength( const wxString &s ) const;
@@ -2246,6 +2248,7 @@ BEGIN_EVENT_TABLE(wxListMainWindow,wxScrolledCanvas)
   EVT_SET_FOCUS      (wxListMainWindow::OnSetFocus)
   EVT_KILL_FOCUS     (wxListMainWindow::OnKillFocus)
   EVT_SCROLLWIN      (wxListMainWindow::OnScroll)
+  EVT_CHILD_FOCUS    (wxListMainWindow::OnChildFocus)
 END_EVENT_TABLE()
 
 void wxListMainWindow::Init()
@@ -2857,6 +2860,11 @@ void wxListMainWindow::HighlightAll( bool on )
     }
 }
 
+void wxListMainWindow::OnChildFocus(wxChildFocusEvent& event)
+{
+    // do nothing
+}
+
 void wxListMainWindow::SendNotify( size_t line,
                                    wxEventType command,
                                    const wxPoint& point )