]> git.saurik.com Git - wxWidgets.git/blobdiff - src/generic/listctrl.cpp
Fix 62 harmless but annoying Clang warnings in wxOSX build.
[wxWidgets.git] / src / generic / listctrl.cpp
index 2b1a22df1e96a506c42e965bcc391c2d3bcd9fe5..d76348f29b017052e66913666b1eb5f2e35291c1 100644 (file)
@@ -934,7 +934,6 @@ void wxListLineData::ReverseHighlight( void )
 BEGIN_EVENT_TABLE(wxListHeaderWindow,wxWindow)
     EVT_PAINT         (wxListHeaderWindow::OnPaint)
     EVT_MOUSE_EVENTS  (wxListHeaderWindow::OnMouse)
-    EVT_SET_FOCUS     (wxListHeaderWindow::OnSetFocus)
 END_EVENT_TABLE()
 
 void wxListHeaderWindow::Init()
@@ -1341,12 +1340,6 @@ void wxListHeaderWindow::OnMouse( wxMouseEvent &event )
     }
 }
 
-void wxListHeaderWindow::OnSetFocus( wxFocusEvent &WXUNUSED(event) )
-{
-    m_owner->SetFocus();
-    m_owner->Update();
-}
-
 bool wxListHeaderWindow::SendListEvent(wxEventType type, const wxPoint& pos)
 {
     wxWindow *parent = GetParent();
@@ -5154,18 +5147,10 @@ void wxGenericListCtrl::DoScreenToClient( int *x, int *y ) const
         wxListCtrlBase::DoScreenToClient(x, y);
 }
 
-void wxGenericListCtrl::SetFocus()
-{
-    // The test in window.cpp fails as we are a composite
-    // window, so it checks against "this", but not m_mainWin.
-    if ( DoFindFocus() != this )
-        m_mainWin->SetFocus();
-}
-
 wxSize wxGenericListCtrl::DoGetBestClientSize() const
 {
-    // Something is better than nothing even if this is completely arbitrary.
-    wxSize sizeBest(100, 80);
+    // The base class version can compute the best size in report view only.
+    wxSize sizeBest = wxListCtrlBase::DoGetBestClientSize();
 
     if ( !InReportView() )
     {