}
 };
 
-WX_DEFINE_ARRAY(wxColWidthInfo *, ColWidthArray);
+WX_DEFINE_ARRAY_PTR(wxColWidthInfo *, ColWidthArray);
 
 //-----------------------------------------------------------------------------
 //  wxListItemData (internal)
 
 void wxListTextCtrl::OnKillFocus( wxFocusEvent &event )
 {
-    if ( !m_finished )
+    if ( !m_finished && !m_aboutToFinish  )
     {
         // We must finish regardless of success, otherwise we'll get
         // focus problems:
 {
     DoDeleteAllItems();
     WX_CLEAR_LIST(wxListHeaderDataList, m_columns);
+    WX_CLEAR_ARRAY(m_aColWidths);
 
     delete m_highlightBrush;
     delete m_highlightUnfocusedBrush;
         ResetVisibleLinesRange();
         for (size_t i = 0; i < m_aColWidths.GetCount(); i++)
         {
-            delete m_aColWidths.Item(i);
+            m_aColWidths.Item(i)->bNeedsUpdate = true;
         }
     }
 
 void wxListMainWindow::DeleteEverything()
 {
     WX_CLEAR_LIST(wxListHeaderDataList, m_columns);
+    WX_CLEAR_ARRAY(m_aColWidths);
 
     DeleteAllItems();
 }
 
         // calculate the width of the item and adjust the max column width
         wxColWidthInfo *pWidthInfo = m_aColWidths.Item(item.GetColumn());
-        int width = 0;
-
-        width = GetItemWidthWithImage(&item);
+        int width = GetItemWidthWithImage(&item);
         item.SetWidth(width);
         if (width > pWidthInfo->nMaxWidth)
             pWidthInfo->nMaxWidth = width;
     ResetVisibleLinesRange();
 
     // FIXME
-#if defined(__WXGTK__) && !defined(__WXUNIVERSAL__)
+#if ( defined(__WXGTK__) || defined(__WXMAC__) ) && !defined(__WXUNIVERSAL__)
     wxScrolledWindow::OnScroll(event);
 #else
     HandleOnScroll( event );