Bug 670338 - Add double overload to NSToIntRound to stop build warnings; r=roc

This commit is contained in:
Ed Morley 2011-07-11 09:14:12 -04:00
parent 4b39be95e2
commit 08c695d2ea

View File

@ -450,6 +450,11 @@ inline PRInt32 NSToIntRound(float aValue)
return NS_lroundf(aValue);
}
inline PRInt32 NSToIntRound(double aValue)
{
return NS_lround(aValue);
}
inline PRInt32 NSToIntRoundUp(float aValue)
{
return PRInt32(NS_floorf(aValue + 0.5f));