mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 907901. Remove NS_lround from rect.h. r=Bas
This commit is contained in:
parent
3aba9bbe8e
commit
2e6bc9e9b5
@ -10,7 +10,8 @@
|
||||
#include "BaseMargin.h"
|
||||
#include "Point.h"
|
||||
#include "Tools.h"
|
||||
#include "nsMathUtils.h"
|
||||
|
||||
#include <cmath>
|
||||
|
||||
namespace mozilla {
|
||||
namespace gfx {
|
||||
@ -108,10 +109,10 @@ typedef RectTyped<UnknownUnits> Rect;
|
||||
template<class units>
|
||||
IntRectTyped<units> RoundedToInt(const RectTyped<units>& aRect)
|
||||
{
|
||||
return IntRectTyped<units>(NS_lround(aRect.x),
|
||||
NS_lround(aRect.y),
|
||||
NS_lround(aRect.width),
|
||||
NS_lround(aRect.height));
|
||||
return IntRectTyped<units>(int32_t(floorf(aRect.x + 0.5f)),
|
||||
int32_t(floorf(aRect.y + 0.5f)),
|
||||
int32_t(floorf(aRect.width + 0.5f)),
|
||||
int32_t(floorf(aRect.height + 0.5f)));
|
||||
}
|
||||
|
||||
template<class units>
|
||||
|
Loading…
Reference in New Issue
Block a user