]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/wincmn.cpp
eVC4 warning fixes.
[wxWidgets.git] / src / common / wincmn.cpp
index 3f659ed9ac383b4a4cbc812d637bbd289ed55272..7a1e6e85774ce0cc5cae664560bb279b1ac936e1 100644 (file)
@@ -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 )