Use rint instead of round.

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@33195 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Fred Kiefer 2011-05-29 18:50:43 +00:00
parent 70f33d157b
commit 7606bc7007
2 changed files with 8 additions and 1 deletions

View file

@ -1,3 +1,8 @@
2011-05-29 Fred Kiefer <FredKiefer@gmx.de>
* Source/NSButtonCell.m (-drawImage:withFrame:inView:): Use rint
instead of round.
2011-05-27 14:08 David Chisnall <theraven@gna.org>
* libs/gui/trunk/Source/NSMenu.m:

View file

@ -59,6 +59,8 @@
#include <math.h>
DEFINE_RINT_IF_MISSING
typedef struct _GSButtonCellFlags
{
#if GS_WORDS_BIGENDIAN == 1
@ -935,7 +937,7 @@ typedef struct _GSButtonCellFlags
{
position = [controlView convertPointToBase: position];
}
position = NSMakePoint(round(position.x), round(position.y));
position = NSMakePoint(rint(position.x), rint(position.y));
if (controlView)
{
position = [controlView convertPointFromBase: position];