]> git.saurik.com Git - wxWidgets.git/commitdiff
Rename wxDataViewCtrl::InvalidateColBestWidth* to UpdateColBestWidth*.
authorVáclav Slavík <vslavik@fastmail.fm>
Sun, 21 Aug 2011 09:07:06 +0000 (09:07 +0000)
committerVáclav Slavík <vslavik@fastmail.fm>
Sun, 21 Aug 2011 09:07:06 +0000 (09:07 +0000)
The new names make it more clear that the functions don't just set an
invalidated flag, but that they actually do some recalculations.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68807 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

include/wx/generic/dataview.h
src/generic/datavgen.cpp

index 6e728635de8ca3180115a5379fe644e6f4846c5d..51c0e590779c52625b79999d8ba0cc25711d5b63 100644 (file)
@@ -224,8 +224,8 @@ private:
     virtual wxDataViewItem DoGetCurrentItem() const;
     virtual void DoSetCurrentItem(const wxDataViewItem& item);
 
-    void InvalidateColBestWidths();
-    void InvalidateColBestWidth(int idx);
+    void UpdateColBestWidths();
+    void UpdateColBestWidth(int idx);
 
     wxDataViewColumnList      m_cols;
     // cached column best widths or 0 if not computed, values are for
index 38ccff89df0842915dc88269feae9e79781fbc3f..650060a5a7ae18f50c40229b1a1ebde25f08e4f9 100644 (file)
@@ -2003,7 +2003,7 @@ bool wxDataViewMainWindow::ItemAdded(const wxDataViewItem & parent, const wxData
         m_count = -1;
     }
 
-    GetOwner()->InvalidateColBestWidths();
+    GetOwner()->UpdateColBestWidths();
     UpdateDisplay();
 
     return true;
@@ -2126,7 +2126,7 @@ bool wxDataViewMainWindow::ItemDeleted(const wxDataViewItem& parent,
     if( m_currentRow > GetRowCount() )
         ChangeCurrentRow(m_count - 1);
 
-    GetOwner()->InvalidateColBestWidths();
+    GetOwner()->UpdateColBestWidths();
     UpdateDisplay();
 
     return true;
@@ -2137,7 +2137,7 @@ bool wxDataViewMainWindow::ItemChanged(const wxDataViewItem & item)
     SortPrepare();
     g_model->Resort();
 
-    GetOwner()->InvalidateColBestWidths();
+    GetOwner()->UpdateColBestWidths();
 
     // Send event
     wxWindow *parent = GetParent();
@@ -2178,7 +2178,7 @@ bool wxDataViewMainWindow::ValueChanged( const wxDataViewItem & item, unsigned i
     SortPrepare();
     g_model->Resort();
 
-    GetOwner()->InvalidateColBestWidth(view_column);
+    GetOwner()->UpdateColBestWidth(view_column);
 
     // Send event
     wxWindow *parent = GetParent();
@@ -2201,7 +2201,7 @@ bool wxDataViewMainWindow::Cleared()
     SortPrepare();
     BuildTree( GetOwner()->GetModel() );
 
-    GetOwner()->InvalidateColBestWidths();
+    GetOwner()->UpdateColBestWidths();
     UpdateDisplay();
 
     return true;
@@ -4400,7 +4400,7 @@ bool wxDataViewCtrl::ClearColumns()
     return true;
 }
 
-void wxDataViewCtrl::InvalidateColBestWidth(int idx)
+void wxDataViewCtrl::UpdateColBestWidth(int idx)
 {
     m_colsBestWidths[idx] = 0;
 
@@ -4408,7 +4408,7 @@ void wxDataViewCtrl::InvalidateColBestWidth(int idx)
         m_headerArea->UpdateColumn(idx);
 }
 
-void wxDataViewCtrl::InvalidateColBestWidths()
+void wxDataViewCtrl::UpdateColBestWidths()
 {
     m_colsBestWidths.clear();
     m_colsBestWidths.resize(m_cols.size());