diff options
author | vng <viktor.govako@gmail.com> | 2012-01-10 18:36:00 +0400 |
---|---|---|
committer | Alex Zolotarev <alex@maps.me> | 2015-09-23 01:31:40 +0300 |
commit | 818e6addf8831b852c9465f3ad945106eb5dca84 (patch) | |
tree | 9d674155949b9f635f85e47fae48f27ea2ed33aa /geometry/rect2d.hpp | |
parent | a8a59f11cb5f19ae0baa51a802874fc1378d0b1e (diff) |
Add ASSERT for m_clipRect.
Diffstat (limited to 'geometry/rect2d.hpp')
-rw-r--r-- | geometry/rect2d.hpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/geometry/rect2d.hpp b/geometry/rect2d.hpp index 3f94f94207..0e4f5e09f2 100644 --- a/geometry/rect2d.hpp +++ b/geometry/rect2d.hpp @@ -82,6 +82,11 @@ namespace m2 m_maxX = m_maxY = impl::min_max_value<T, IsSigned>().get_max(); } + bool IsValid() const + { + return (m_minX <= m_maxX && m_minY <= m_maxY); + } + void Add(m2::Point<T> const & p) { m_minX = min(p.x, m_minX); |