Implement wxWindow::DoGetBorderSize() in the trivial case of wxBORDER_NONE.

This fixes an assert in wxGenericStaticText which overrode
DoGetBestClientSize() but not DoGetBorderSize().

It would still be useful to implement DoGetBorderSize() in wxGTK (and other
ports) in general too as using wxGenericStaticText with non-default border
still doesn't work.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@62820 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2009-12-08 15:56:14 +00:00
parent efc8837250
commit d7d943a71c
2 changed files with 18 additions and 8 deletions

View File

@@ -1671,14 +1671,9 @@ protected:
// of the left and the right border in the x component of the returned size
// and the sum of the heights of the top and bottom borders in the y one
//
// NB: this is new/temporary API only implemented by wxMSW and wxUniv so
// far and subject to change, don't use
virtual wxSize DoGetBorderSize() const
{
wxFAIL_MSG( "must be overridden if called" );
return wxDefaultSize;
}
// NB: this is currently only implemented by wxMSW and wxUniv so far and
// simply asserts in the other ports
virtual wxSize DoGetBorderSize() const;
// move the window to the specified location and resize it: this is called
// from both DoSetSize() and DoSetClientSize() and would usually just