call SetHorizontalExtent() from SetString(); also simplified/cleaned up the former function and call InvalidateBestSize() from it automatically now

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@40077 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2006-07-12 21:44:34 +00:00
parent 7521630773
commit fca418ae12
2 changed files with 41 additions and 57 deletions

View File

@@ -105,9 +105,10 @@ public:
int GetItemIndex(wxOwnerDrawn *item) const { return m_aItems.Index(item); }
#endif // wxUSE_OWNER_DRAWN
// Windows-specific code to set the horizontal extent of the listbox, if
// necessary. If s is non-NULL, it's used to calculate the horizontal
// extent. Otherwise, all strings are used.
// Windows-specific code to update the horizontal extent of the listbox, if
// necessary. If s is non-empty, the horizontal extent is increased to the
// length of this string if it's currently too short, otherwise the maximum
// extent of all strings is used. In any case calls InvalidateBestSize()
virtual void SetHorizontalExtent(const wxString& s = wxEmptyString);
// Windows callbacks