diff --git a/gfx/public/nsCoord.h b/gfx/public/nsCoord.h index 9e32972dc33..5b185304ac8 100644 --- a/gfx/public/nsCoord.h +++ b/gfx/public/nsCoord.h @@ -60,13 +60,6 @@ // change the definition of nscoord in gfx/idl/gfxtypes.idl. //#define NS_COORD_IS_FLOAT -inline void VERIFY_COORD(nscoord aCoord) { -#ifdef NS_COORD_IS_FLOAT - NS_ASSERTION(floorf(aCoord) == aCoord, - "Coords cannot have fractions"); -#endif -} - inline float NS_IEEEPositiveInfinity() { float f; *(PRUint32*)&f = 0x7F800000; @@ -88,6 +81,13 @@ typedef PRInt32 nscoord; #define nscoord_MIN (-nscoord_MAX) +inline void VERIFY_COORD(nscoord aCoord) { +#ifdef NS_COORD_IS_FLOAT + NS_ASSERTION(floorf(aCoord) == aCoord, + "Coords cannot have fractions"); +#endif +} + inline nscoord NSCoordMultiply(nscoord aCoord, float aVal) { VERIFY_COORD(aCoord); #ifdef NS_COORD_IS_FLOAT