diff -r d9add21ee9d3 -r 51c69652a9d0 mapobj.cpp --- a/mapobj.cpp Wed Apr 25 16:02:54 2007 +0000 +++ b/mapobj.cpp Fri Feb 01 15:28:35 2008 +0000 @@ -102,49 +102,16 @@ clickBox.moveTo (clickBox.x()+x,clickBox.y()+y); } -bool MapObj::inBox(const QPointF &p) -{ - if (p.x() >= clickBox.left() && p.x() <= clickBox.right() - && p.y() <= clickBox.bottom() && p.y() >= clickBox.top() ) - return true; - return false; -} - QRectF MapObj::getBBox() { return bbox; } -QRectF MapObj::addBBox(QRectF r1, QRectF r2) -{ - // Find smallest QRectF containing given rectangles +QRectF MapObj::getClickBox() +{ + return clickBox; +} - QRectF n; - // Set left border - if (r1.left() <= r2.left() ) - n.setLeft(r1.left() ); - else - n.setLeft(r2.left() ); - - // Set top border - if (r1.top() <= r2.top() ) - n.setTop(r1.top() ); - else - n.setTop(r2.top() ); - - // Set right border - if (r1.right() <= r2.right() ) - n.setRight(r2.right() ); - else - n.setRight(r1.right() ); - - // Set bottom - if (r1.bottom() <= r2.bottom() ) - n.setBottom(r2.bottom() ); - else - n.setBottom(r1.bottom() ); - return n; -} QSizeF MapObj::getSize() {