(svn r11583) -Fix [FS#1484]: windows could get completely missing when one resized the window to something very small.
authorrubidium
Thu, 06 Dec 2007 20:55:48 +0000
changeset 8519 7a9d047a184e
parent 8518 08fc9e9bbddd
child 8520 f11cbfab944c
(svn r11583) -Fix [FS#1484]: windows could get completely missing when one resized the window to something very small.
src/window.cpp
--- a/src/window.cpp	Thu Dec 06 20:48:15 2007 +0000
+++ b/src/window.cpp	Thu Dec 06 20:55:48 2007 +0000
@@ -2197,8 +2197,11 @@
 			default:
 				left = w->left;
 				if (left + (w->width >> 1) >= neww) left = neww - w->width;
+				if (left < 0) left = 0;
+
 				top = w->top;
 				if (top + (w->height >> 1) >= newh) top = newh - w->height;
+				if (top < 0) top = 0;
 				break;
 		}