Remove unused and confusing API in TRect.
This commit is contained in:
@@ -59,24 +59,20 @@ struct TSize {
|
||||
return {width - s.width, height - s.height};
|
||||
}
|
||||
|
||||
constexpr TSize Min(const TSize& s) const { return Intersection(s); }
|
||||
|
||||
constexpr TSize Max(const TSize& s) const { return Union(s); }
|
||||
|
||||
constexpr TSize Union(const TSize& o) const {
|
||||
return {
|
||||
std::max(width, o.width),
|
||||
std::max(height, o.height),
|
||||
};
|
||||
}
|
||||
|
||||
constexpr TSize Intersection(const TSize& o) const {
|
||||
constexpr TSize Min(const TSize& o) const {
|
||||
return {
|
||||
std::min(width, o.width),
|
||||
std::min(height, o.height),
|
||||
};
|
||||
}
|
||||
|
||||
constexpr TSize Max(const TSize& o) const {
|
||||
return {
|
||||
std::max(width, o.width),
|
||||
std::max(height, o.height),
|
||||
};
|
||||
}
|
||||
|
||||
constexpr Type Area() const { return width * height; }
|
||||
|
||||
constexpr bool IsPositive() const { return width > 0 && height > 0; }
|
||||
|
||||
Reference in New Issue
Block a user