Skip to content

Commit 1f81a84

Browse files
committedOct 28, 2013
Merge pull request #974 from leyan/topology_bug
correct bug in topology rubberband when OTF is enabled
2 parents 5aac8bb + 990a25a commit 1f81a84

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed
 

‎src/app/nodetool/qgsmaptoolnodetool.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ void QgsMapToolNodeTool::createTopologyRubberBands( QgsVectorLayer* vlayer, cons
187187
}
188188
else
189189
{
190-
trb->addPoint( topolGeometry->vertexAt( tVertex ) );
190+
trb->addPoint( toMapCoordinates( vlayer, topolGeometry->vertexAt( tVertex ) ) );
191191
if ( tVertex == tVertexFirst ) // cycle first vertex need to be added also
192192
{
193193
movingPoints->insert( movingPointIndex );
@@ -206,14 +206,14 @@ void QgsMapToolNodeTool::createTopologyRubberBands( QgsVectorLayer* vlayer, cons
206206
// find first no matching vertex
207207
if ( dist > ZERO_TOLERANCE || !vertexMap[at]->isSelected() ) // problem with double precision
208208
{
209-
trb->addPoint( topolGeometry->vertexAt( tVertex ) );
209+
trb->addPoint( toMapCoordinates( vlayer, topolGeometry->vertexAt( tVertex ) ) );
210210
break; // found first vertex
211211
}
212212
else // add moving point to rubberband
213213
{
214214
if ( addedPoints->contains( tVertex ) )
215215
break; // just preventing to circle
216-
trb->addPoint( topolGeometry->vertexAt( tVertex ) );
216+
trb->addPoint( toMapCoordinates( vlayer, topolGeometry->vertexAt( tVertex ) ) );
217217
movingPoints->insert( movingPointIndex );
218218
movingPointIndex++;
219219
addedPoints->insert( tVertex );

0 commit comments

Comments
 (0)
Please sign in to comment.