Order fix.
[wxWidgets.git] / src / mac / carbon / toplevel.cpp
index c4914ac596a486242fbf70985ac4ee284af73bd2..a459279ecc332ee2b3f7f4c4aad56a5c3326317c 100644 (file)
@@ -948,10 +948,14 @@ void  wxTopLevelWindowMac::MacCreateRealWindow( const wxString& title,
 
     int x = (int)pos.x;
     int y = (int)pos.y;
-    if ( y < 50 )
-        y = 50 ;
-    if ( x < 20 )
-        x = 20 ;
+    
+    wxRect display = wxGetClientDisplayRect() ;
+
+    if ( x == wxDefaultPosition.x )
+        x = display.x ;
+    
+    if ( y == wxDefaultPosition.y )
+        y = display.y ;
 
     int w = WidthDefault(size.x);
     int h = HeightDefault(size.y);