From a31fd7f86bea249135b66010569c22982e0015af Mon Sep 17 00:00:00 2001 From: Emmanuel Gil Peyrot Date: Thu, 14 May 2015 16:16:15 +0200 Subject: Common: Remove unused cruft from math_util, and remove a duplicated Rect class in common_types. --- src/common/common_types.h | 26 -------------------------- 1 file changed, 26 deletions(-) (limited to 'src/common/common_types.h') 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_); - } -}; -} -- cgit v1.2.3