make sure all the rubber band frames are deleted in composer. Fixes bug #1573

git-svn-id: http://svn.osgeo.org/qgis/trunk@10544 c8812cc2-4d05-0410-92ff-de0c093fc19c
This commit is contained in:
mhugent 2009-04-12 10:12:07 +00:00
parent 24e6248330
commit a012920c57

View File

@ -237,6 +237,13 @@ void QgsComposerItem::mousePressEvent( QGraphicsSceneMouseEvent * event )
mLastMouseEventPos = event->lastScenePos();
mCurrentMouseMoveAction = mouseMoveActionForPosition( event->pos() );
//remove the old rubber band item if it is still there
if ( mBoundingResizeRectangle )
{
scene()->removeItem( mBoundingResizeRectangle );
delete mBoundingResizeRectangle;
mBoundingResizeRectangle = 0;
}
//create and show bounding rectangle
mBoundingResizeRectangle = new QGraphicsRectItem( 0 );
scene()->addItem( mBoundingResizeRectangle );