]> git.saurik.com Git - wxWidgets.git/commitdiff
invalidate field-width cache when changing field count
authorDimitri Schoolwerth <dimitri.schoolwerth@gmail.com>
Mon, 23 Aug 2004 22:27:11 +0000 (22:27 +0000)
committerDimitri Schoolwerth <dimitri.schoolwerth@gmail.com>
Mon, 23 Aug 2004 22:27:11 +0000 (22:27 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@28873 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/generic/statusbr.cpp

index fea9c6ad980349d54f4849cacf6e568521cda2bd..831d2d8717e73454eccb8cd5ab742341b9f31f5a 100644 (file)
@@ -142,6 +142,9 @@ void wxStatusBarGeneric::SetFieldsCount(int number, const int *widths)
 
     wxStatusBarBase::SetFieldsCount(number, widths);
 
+    // forget the old cached pixel widths
+    m_widthsAbs.Empty();
+
     wxASSERT_MSG( m_nFields == (int)m_statusStrings.GetCount(),
                   _T("This really should never happen, can we do away with m_nFields here?") );
 }