diff options
Diffstat (limited to 'src/common/common_types.h')
-rw-r--r-- | src/common/common_types.h | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/src/common/common_types.h b/src/common/common_types.h index 644709ba..f6de0adf 100644 --- a/src/common/common_types.h +++ b/src/common/common_types.h @@ -87,29 +87,3 @@ protected: NonCopyable(NonCopyable&) = delete; NonCopyable& operator=(NonCopyable&) = delete; }; - -namespace Common { -/// Rectangle data structure -class Rect { -public: - Rect(int x0=0, int y0=0, int x1=0, int y1=0) { - x0_ = x0; - y0_ = y0; - x1_ = x1; - y1_ = y1; - } - ~Rect() { } - - int x0_; ///< Rect top left X-coordinate - int y0_; ///< Rect top left Y-coordinate - int x1_; ///< Rect bottom left X-coordinate - int y1_; ///< Rect bottom right Y-coordinate - - inline u32 width() const { return std::abs(x1_ - x0_); } - inline u32 height() const { return std::abs(y1_ - y0_); } - - inline bool operator == (const Rect& val) const { - return (x0_ == val.x0_ && y0_ == val.y0_ && x1_ == val.x1_ && y1_ == val.y1_); - } -}; -} |