BRect's OffsetBy takes a BPoint. Add a similar BRegion method to be more consistent. This one takes a const reference instead a complete BPoint object.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42476 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Clemens Zeidler 2011-07-24 23:53:12 +00:00
parent f7953fa769
commit c0dad949ee
2 changed files with 9 additions and 0 deletions

View File

@ -56,6 +56,7 @@ public:
void PrintToStream() const;
void OffsetBy(const BPoint& point);
void OffsetBy(int32 x, int32 y);
void MakeEmpty();

View File

@ -342,6 +342,14 @@ BRegion::PrintToStream() const
// #pragma mark -
void
BRegion::OffsetBy(const BPoint& point)
{
OffsetBy(point.x, point.y);
}
/*! \brief Offsets all region's rects, and bounds by the given values.
\param dh The horizontal offset.
\param dv The vertical offset.