Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Correct topology rubber band bug for first and last vertexes
  • Loading branch information
leyan committed Oct 26, 2013
1 parent 00c0cef commit 2689f99
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/app/nodetool/qgsmaptoolnodetool.cpp
Expand Up @@ -311,7 +311,7 @@ void QgsMapToolNodeTool::canvasMoveEvent( QMouseEvent * e )
offset = posMapCoord - mPosMapCoordBackup;
for ( int i = 0; i < mTopologyRubberBand.size(); i++ )
{
for ( int pointIndex = 0; pointIndex < mTopologyRubberBand[i]->numberOfVertices() - 1; pointIndex++ )
for ( int pointIndex = 0; pointIndex < mTopologyRubberBand[i]->numberOfVertices(); pointIndex++ )
{
if ( mTopologyRubberBandVertexes[i]->contains( pointIndex ) )
{
Expand All @@ -321,10 +321,6 @@ void QgsMapToolNodeTool::canvasMoveEvent( QMouseEvent * e )
break;
}
mTopologyRubberBand[i]->movePoint( pointIndex, *point + offset );
if ( pointIndex == 0 )
{
mTopologyRubberBand[i]->movePoint( pointIndex, *point + offset );
}
}
}
}
Expand Down

0 comments on commit 2689f99

Please sign in to comment.