diff options
author | Einar Johan Trøan Sømåen | 2012-08-31 17:37:25 +0200 |
---|---|---|
committer | Einar Johan Trøan Sømåen | 2012-08-31 17:37:25 +0200 |
commit | 969f4d5947b6a36d66c12c510b8fe623e1782bbd (patch) | |
tree | 8ec201f8bbaec880a0e66949ecd71b75bf925b35 /engines/wintermute/math/rect32.h | |
parent | 8a212c3b6cb5100d750fb3025e79af64e4ed86e4 (diff) | |
download | scummvm-rg350-969f4d5947b6a36d66c12c510b8fe623e1782bbd.tar.gz scummvm-rg350-969f4d5947b6a36d66c12c510b8fe623e1782bbd.tar.bz2 scummvm-rg350-969f4d5947b6a36d66c12c510b8fe623e1782bbd.zip |
WINTERMUTE: Take int32 as parameters in Rect32.
Diffstat (limited to 'engines/wintermute/math/rect32.h')
-rw-r--r-- | engines/wintermute/math/rect32.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/engines/wintermute/math/rect32.h b/engines/wintermute/math/rect32.h index 51a1be15e4..1c959da1cf 100644 --- a/engines/wintermute/math/rect32.h +++ b/engines/wintermute/math/rect32.h @@ -37,8 +37,8 @@ struct Rect32 { int32 bottom, right; ///< The point at the bottom right of the rectangle (not part of the rect). Rect32() : top(0), left(0), bottom(0), right(0) {} - Rect32(int16 w, int16 h) : top(0), left(0), bottom(h), right(w) {} - Rect32(int16 x1, int16 y1, int16 x2, int16 y2) : top(y1), left(x1), bottom(y2), right(x2) { + Rect32(int32 w, int32 h) : top(0), left(0), bottom(h), right(w) {} + Rect32(int32 x1, int32 y1, int32 x2, int32 y2) : top(y1), left(x1), bottom(y2), right(x2) { assert(isValidRect()); } bool operator==(const Rect32 &rhs) const { @@ -48,18 +48,18 @@ struct Rect32 { return !equals(rhs); } - int16 width() const { + int32 width() const { return right - left; } - int16 height() const { + int32 height() const { return bottom - top; } - void setWidth(int16 aWidth) { + void setWidth(int32 aWidth) { right = left + aWidth; } - void setHeight(int16 aHeight) { + void setHeight(int32 aHeight) { bottom = top + aHeight; } |