]> git.saurik.com Git - wxWidgets.git/commitdiff
Check wxSIZE_ALLOW_MINUS_ONE for x and y too.
authorRobin Dunn <robin@alldunn.com>
Fri, 19 Sep 2003 22:32:24 +0000 (22:32 +0000)
committerRobin Dunn <robin@alldunn.com>
Fri, 19 Sep 2003 22:32:24 +0000 (22:32 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@23730 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/gtk/window.cpp
src/gtk1/window.cpp

index 01b6002214fa99436ad1a49cf6b56dd0cbffb951..9ad817a824b0e500d846f3b4a779b56f330adf17 100644 (file)
@@ -2883,9 +2883,9 @@ void wxWindowGTK::DoSetSize( int x, int y, int width, int height, int sizeFlags
 
     int currentX, currentY;
     GetPosition(&currentX, &currentY);
-    if (x == -1)
+    if (x == -1 && !(sizeFlags & wxSIZE_ALLOW_MINUS_ONE))
         x = currentX;
-    if (y == -1)
+    if (y == -1 && !(sizeFlags & wxSIZE_ALLOW_MINUS_ONE))
         y = currentY;
     AdjustForParentClientOrigin(x, y, sizeFlags);
 
index 01b6002214fa99436ad1a49cf6b56dd0cbffb951..9ad817a824b0e500d846f3b4a779b56f330adf17 100644 (file)
@@ -2883,9 +2883,9 @@ void wxWindowGTK::DoSetSize( int x, int y, int width, int height, int sizeFlags
 
     int currentX, currentY;
     GetPosition(&currentX, &currentY);
-    if (x == -1)
+    if (x == -1 && !(sizeFlags & wxSIZE_ALLOW_MINUS_ONE))
         x = currentX;
-    if (y == -1)
+    if (y == -1 && !(sizeFlags & wxSIZE_ALLOW_MINUS_ONE))
         y = currentY;
     AdjustForParentClientOrigin(x, y, sizeFlags);