Clarify wxButton::AdjustForBitmapSize() semantics in wxMSW.
This method should only be called if we do have an image, assert (instead of silently returning) if it's called when we don't. Also explain in a comment why do we need to call CacheBestSize() only when we have an image in DoGetBestSize(). git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66890 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -88,8 +88,10 @@ protected:
|
||||
virtual void DoSetBitmapMargins(wxCoord x, wxCoord y);
|
||||
virtual void DoSetBitmapPosition(wxDirection dir);
|
||||
|
||||
// Increases the passed in size if necessary to account for the
|
||||
// button image, if any
|
||||
// Increases the passed in size to account for the button image.
|
||||
//
|
||||
// Should only be called if we do have a button, i.e. if m_imageData is
|
||||
// non-NULL.
|
||||
void AdjustForBitmapSize(wxSize& size) const;
|
||||
|
||||
class wxButtonImageData *m_imageData;
|
||||
|
Reference in New Issue
Block a user