]> git.saurik.com Git - wxWidgets.git/commitdiff
Use WidthDefault and HeightDefault
authorRobin Dunn <robin@alldunn.com>
Fri, 5 Mar 2004 23:36:20 +0000 (23:36 +0000)
committerRobin Dunn <robin@alldunn.com>
Fri, 5 Mar 2004 23:36:20 +0000 (23:36 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@26106 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/mac/carbon/toplevel.cpp
src/mac/toplevel.cpp

index 67a8669f690a21e8a597a9a466b6c2dbbc3653e1..a76f43123dfbbdbac3efb9fb2c12de3916210cd2 100644 (file)
@@ -657,12 +657,8 @@ void  wxTopLevelWindowMac::MacCreateRealWindow( const wxString& title,
     if ( m_x < 20 )
         m_x = 20 ;
 
-    m_width = size.x;
-    if (m_width == -1)
-        m_width = 20;
-    m_height = size.y;
-    if (m_height == -1)
-        m_height = 20;
+    m_width = WidthDefault(size.x);
+    m_height = HeightDefault(size.y);
 
     ::SetRect(&theBoundsRect, m_x, m_y , m_x + m_width, m_y + m_height);
 
index 67a8669f690a21e8a597a9a466b6c2dbbc3653e1..a76f43123dfbbdbac3efb9fb2c12de3916210cd2 100644 (file)
@@ -657,12 +657,8 @@ void  wxTopLevelWindowMac::MacCreateRealWindow( const wxString& title,
     if ( m_x < 20 )
         m_x = 20 ;
 
-    m_width = size.x;
-    if (m_width == -1)
-        m_width = 20;
-    m_height = size.y;
-    if (m_height == -1)
-        m_height = 20;
+    m_width = WidthDefault(size.x);
+    m_height = HeightDefault(size.y);
 
     ::SetRect(&theBoundsRect, m_x, m_y , m_x + m_width, m_y + m_height);