Skip to content
Permalink
Browse files

rename enum to avoid confusion

  • Loading branch information
3nids committed Aug 12, 2016
1 parent af1fee5 commit 99ed790820dabfdfe363effd30b546cc093ec242
@@ -52,11 +52,11 @@ class QgsAdvancedDigitizingDockWidget : QDockWidget
/**
* Determines if the dock has to record one, two or many points.
*/
enum CaptureMode
enum AdvancedDigitizingMode
{
SinglePoint, //!< Capture a single point (e.g. for point digitizing)
TwoPoints, //!< Capture two points (e.g. for translation)
ManyPoints //!< Capture many points (e.g. line or polygon digitizing)
ManyPoints //!< Capture two or more points (e.g. line or polygon digitizing)
};

/**
@@ -182,7 +182,7 @@ class QgsAdvancedDigitizingDockWidget : QDockWidget
* @param mode determines if the dock has to record one, two or many points.
* @return If the event is hidden (construction mode hides events from the maptool)
*/
bool canvasReleaseEvent( QgsMapMouseEvent* e , CaptureMode mode );
bool canvasReleaseEvent( QgsMapMouseEvent* e, AdvancedDigitizingMode mode );
/**
* Will react on a canvas move event
*
@@ -900,7 +900,7 @@ bool QgsAdvancedDigitizingDockWidget::canvasPressEvent( QgsMapMouseEvent* e )
return mCadEnabled && mConstructionMode;
}

bool QgsAdvancedDigitizingDockWidget::canvasReleaseEvent( QgsMapMouseEvent* e, CaptureMode mode )
bool QgsAdvancedDigitizingDockWidget::canvasReleaseEvent( QgsMapMouseEvent* e, AdvancedDigitizingMode mode )
{
if ( !mCadEnabled )
return false;
@@ -73,11 +73,11 @@ class GUI_EXPORT QgsAdvancedDigitizingDockWidget : public QgsDockWidget, private
/**
* Determines if the dock has to record one, two or many points.
*/
enum CaptureMode
enum AdvancedDigitizingMode
{
SinglePoint, //!< Capture a single point (e.g. for point digitizing)
TwoPoints, //!< Capture two points (e.g. for translation)
ManyPoints //!< Capture many points (e.g. line or polygon digitizing)
ManyPoints //!< Capture two or more points (e.g. line or polygon digitizing)
};

/** \ingroup gui
@@ -222,7 +222,7 @@ class GUI_EXPORT QgsAdvancedDigitizingDockWidget : public QgsDockWidget, private
* @param mode determines if the dock has to record one, two or many points.
* @return If the event is hidden (construction mode hides events from the maptool)
*/
bool canvasReleaseEvent( QgsMapMouseEvent* e , CaptureMode mode );
bool canvasReleaseEvent( QgsMapMouseEvent* e, AdvancedDigitizingMode mode );
/**
* Will react on a canvas move event
*
@@ -44,7 +44,7 @@ void QgsMapToolAdvancedDigitizing::canvasReleaseEvent( QgsMapMouseEvent* e )
{
snap( e );

QgsAdvancedDigitizingDockWidget::CaptureMode dockMode;
QgsAdvancedDigitizingDockWidget::AdvancedDigitizingMode dockMode;
switch ( mCaptureMode )
{
case CaptureLine:

0 comments on commit 99ed790

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