Skip to content
Permalink
Browse files

Hide temporary rubberband when maptool is not active.

  • Loading branch information
SebDieBln committed Dec 16, 2015
1 parent a66a8ea commit e8ef77e781479fa776f54a9086ef2a24f9b06fe1
Showing with 17 additions and 0 deletions.
  1. +3 −0 python/gui/qgsmaptoolcapture.sip
  2. +11 −0 src/gui/qgsmaptoolcapture.cpp
  3. +3 −0 src/gui/qgsmaptoolcapture.h
@@ -25,6 +25,9 @@ class QgsMapToolCapture : public QgsMapToolAdvancedDigitizing
//! destructor
virtual ~QgsMapToolCapture();

//! active the tool
virtual void activate();

//! deactive the tool
virtual void deactivate();

@@ -75,8 +75,19 @@ QgsMapToolCapture::~QgsMapToolCapture()
}
}

void QgsMapToolCapture::activate()
{
if ( mTempRubberBand )
mTempRubberBand->show();

QgsMapToolAdvancedDigitizing::activate();
}

void QgsMapToolCapture::deactivate()
{
if ( mTempRubberBand )
mTempRubberBand->hide();

delete mSnappingMarker;
mSnappingMarker = nullptr;

@@ -42,6 +42,9 @@ class GUI_EXPORT QgsMapToolCapture : public QgsMapToolAdvancedDigitizing
//! destructor
virtual ~QgsMapToolCapture();

//! active the tool
virtual void activate() override;

//! deactive the tool
virtual void deactivate() override;

0 comments on commit e8ef77e

Please sign in to comment.
You can’t perform that action at this time.