Several minor bugfixes

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@3576 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
richard 1999-01-19 10:55:24 +00:00
parent 185e4ef945
commit 9ddd4532b3
3 changed files with 15 additions and 1 deletions

View file

@ -376,6 +376,9 @@ NSSize old_size = frame.size;
{
float sx, sy;
if (aRect.size.width <= 0 || aRect.size.height <= 0)
[NSException raise: NSInvalidArgumentException
format: @"illegal bounds size supplied"];
bounds = aRect;
[boundsMatrix setFrameOrigin: NSMakePoint(-bounds.origin.x,
-bounds.origin.y)];
@ -408,6 +411,9 @@ float sx, sy;
{
float sx, sy;
if (newSize.width <= 0 || newSize.height <= 0)
[NSException raise: NSInvalidArgumentException
format: @"illegal bounds size supplied"];
bounds.size = newSize;
sx = frame.size.width / bounds.size.width;
sy = frame.size.height / bounds.size.height;