* expose the XOR function for BRegions (for now called "ExclusiveInclude")
which already existed in the region backend ported from XOrg git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23394 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -66,6 +66,8 @@ class BRegion {
|
|||||||
|
|
||||||
void IntersectWith(const BRegion* region);
|
void IntersectWith(const BRegion* region);
|
||||||
|
|
||||||
|
void ExclusiveInclude(const BRegion* region);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
friend class BDirectWindow;
|
friend class BDirectWindow;
|
||||||
friend class BPrivate::ServerLink;
|
friend class BPrivate::ServerLink;
|
||||||
|
|||||||
@@ -414,7 +414,7 @@ BRegion::Exclude(const BRegion* region)
|
|||||||
|
|
||||||
/*! \brief Modifies the region, so that it will contain just the area
|
/*! \brief Modifies the region, so that it will contain just the area
|
||||||
in common with the given BRegion.
|
in common with the given BRegion.
|
||||||
\param region the BRegion to intersect to.
|
\param region the BRegion to intersect with.
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
BRegion::IntersectWith(const BRegion* region)
|
BRegion::IntersectWith(const BRegion* region)
|
||||||
@@ -429,6 +429,23 @@ BRegion::IntersectWith(const BRegion* region)
|
|||||||
// #pragma mark -
|
// #pragma mark -
|
||||||
|
|
||||||
|
|
||||||
|
/*! \brief Modifies the region, so that it will contain just the area
|
||||||
|
which both regions do not have in common.
|
||||||
|
\param region the BRegion to exclusively include.
|
||||||
|
*/
|
||||||
|
void
|
||||||
|
BRegion::ExclusiveInclude(const BRegion* region)
|
||||||
|
{
|
||||||
|
BRegion result;
|
||||||
|
Support::XXorRegion(this, region, &result);
|
||||||
|
|
||||||
|
_AdoptRegionData(result);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// #pragma mark -
|
||||||
|
|
||||||
|
|
||||||
/*! \brief Takes over the data of a region and marks that region empty.
|
/*! \brief Takes over the data of a region and marks that region empty.
|
||||||
\param region The region to adopt the data from.
|
\param region The region to adopt the data from.
|
||||||
*/
|
*/
|
||||||
@@ -501,6 +518,7 @@ BRegion::_SetSize(long newSize)
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
clipping_rect
|
clipping_rect
|
||||||
BRegion::_Convert(const BRect& rect) const
|
BRegion::_Convert(const BRect& rect) const
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user