X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/8907154c1a8a6882c6797d1f16393ddfb23e7f3a..41e155b43e45b056738bfd7e25c8c7fe261243f3:/src/common/wincmn.cpp diff --git a/src/common/wincmn.cpp b/src/common/wincmn.cpp index e6d1cb88e0..7a1e6e8577 100644 --- a/src/common/wincmn.cpp +++ b/src/common/wincmn.cpp @@ -528,9 +528,9 @@ void wxWindowBase::Centre(int direction) // fits the window around the children void wxWindowBase::Fit() { - if ( GetChildren().GetCount() > 0 ) + if ( !GetChildren().empty() ) { - SetSize(GetBestSize()); + SetClientSize(GetBestSize()); } //else: do nothing if we have no children } @@ -579,7 +579,7 @@ wxSize wxWindowBase::DoGetBestSize() const if ( m_windowSizer ) { - best = m_windowSizer->GetMinSize(); + best = GetWindowSizeForVirtualSize(m_windowSizer->GetMinSize()); } #if wxUSE_CONSTRAINTS else if ( m_constraints ) @@ -2280,7 +2280,7 @@ void wxWindowBase::OnMiddleClick( wxMouseEvent& event ) wxMessageBox(wxString::Format( _T( - " wxWidgets Library (%s port)\nVersion %u.%u.%u%s%s, compiled at %s %s\n Copyright (c) 1995-2005 wxWidgets team" + " wxWidgets Library (%s port)\nVersion %d.%d.%d%s%s, compiled at %s %s\n Copyright (c) 1995-2005 wxWidgets team" ), port.c_str(), wxMAJOR_VERSION,