- // refresh entirely, shouldn't matter much as the statusbar is quick to
- // redraw and it would be difficult to avoid it as we'd need to find out
- // which fields exactly were affected...
- Refresh();
+ if ( field < m_nFields )
+ {
+ // call this before invalidating the old widths as we want to use them,
+ // not the new ones
+ wxRect rect = DoGetFieldRect(field);
+
+ // invalidate the widths, we'll have to recalc them
+ m_widthsAbs.Empty();
+
+ // refresh everything after the first invalid field
+ rect.y = 0;
+ rect.SetRight(event.GetSize().x);
+ rect.height = event.GetSize().y;
+ RefreshRect(rect);
+ }