]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/toplvcmn.cpp
Pass correct values to spin control
[wxWidgets.git] / src / common / toplvcmn.cpp
index 97821d0d69fc28730e0edb7376426673a4125224..2b20827bc1d5013ac121587d4be936dfadae345d 100644 (file)
@@ -173,22 +173,6 @@ void wxTopLevelWindowBase::GetRectForTopLevelChildren(int *x, int *y, int *w, in
     GetSize(w,h);
 }
 
-wxSize wxTopLevelWindowBase::GetMaxSize() const
-{
-    wxSize size = wxWindow::GetMaxSize();
-
-    int w, h;
-    wxClientDisplayRect(NULL, NULL, &w, &h );
-
-    if ( size.GetWidth() == wxDefaultCoord )
-        size.SetWidth(w);
-
-    if ( size.GetHeight() == wxDefaultCoord )
-        size.SetHeight(h);
-
-    return size;
-}
-
 /* static */
 wxSize wxTopLevelWindowBase::GetDefaultSize()
 {
@@ -374,21 +358,7 @@ void wxTopLevelWindowBase::DoLayout()
             int clientW, clientH;
             DoGetClientSize(&clientW, &clientH);
 
-            // for whatever reasons, wxGTK wants to have a small offset - it
-            // probably looks better with it?
-#ifdef __WXGTK__
-            const int ofs = 1;
-            clientW -= 2 * ofs;
-            clientH -= 2 * ofs;
-            if (clientW < 0)
-                clientW = 0;
-            if (clientH < 0)
-                clientH = 0;
-#else
-            const int ofs = 0;
-#endif
-
-            child->SetSize(ofs, ofs, clientW, clientH);
+            child->SetSize(0, 0, clientW, clientH);
         }
     }
 }