]> git.saurik.com Git - wxWidgets.git/blobdiff - src/generic/listctrl.cpp
better native types for carbon
[wxWidgets.git] / src / generic / listctrl.cpp
index 07126a38a7c739bc4cd71e58b4e63331f634f3a1..dbc1eeec4d1155576d46eb8aa91e28704151f303 100644 (file)
@@ -1227,7 +1227,7 @@ void wxListHeaderWindow::DrawCurrent()
 
     wxScreenDC dc;
     dc.SetLogicalFunction( wxINVERT );
-    dc.SetPen( wxPen( *wxBLACK, 2, wxSOLID ) );
+    dc.SetPen( wxPen(*wxBLACK, 2) );
     dc.SetBrush( *wxTRANSPARENT_BRUSH );
 
     AdjustDC(dc);
@@ -1555,7 +1555,7 @@ void wxListTextCtrlWrapper::OnKillFocus( wxFocusEvent &event )
 //  wxListMainWindow
 //-----------------------------------------------------------------------------
 
-BEGIN_EVENT_TABLE(wxListMainWindow,wxScrolledCanvas)
+BEGIN_EVENT_TABLE(wxListMainWindow, wxWindow)
   EVT_PAINT          (wxListMainWindow::OnPaint)
   EVT_MOUSE_EVENTS   (wxListMainWindow::OnMouse)
   EVT_CHAR           (wxListMainWindow::OnChar)
@@ -2243,6 +2243,9 @@ wxTextCtrl *wxListMainWindow::EditLabel(long item, wxClassInfo* textControlClass
     // been added and no screen update taken place.
     if ( m_dirty )
     {
+        // TODO: use wxTheApp->SafeYieldFor(NULL, wxEVT_CATEGORY_UI) instead
+        //       so that no pending events may change the item count (see below)
+        //       IMPORTANT: needs to be tested!
         wxSafeYield();
 
         // Pending events dispatched by wxSafeYield might have changed the item
@@ -4302,13 +4305,9 @@ void wxGenericListCtrl::CreateOrDestroyHeaderWindowAsNeeded()
                         wxTAB_TRAVERSAL
                       );
 
-#if defined( __WXMAC__ ) && wxOSX_USE_COCOA_OR_CARBON
+#if defined( __WXMAC__ )
         wxFont font;
-#if wxOSX_USE_ATSU_TEXT
-        font.MacCreateFromThemeFont( kThemeSmallSystemFont );
-#else
-        font.MacCreateFromUIFont( kCTFontSystemFontType );
-#endif
+        font.CreateSystemFont( wxOSX_SYSTEM_FONT_SMALL );
         m_headerWin->SetFont( font );
 #endif