Skip to content
Permalink
Browse files

Fix tests

  • Loading branch information
wonder-sk authored and nirvn committed Feb 15, 2019
1 parent 7b97723 commit 36e0233981374935f0f2c3e40038b57625c65804
Showing with 5 additions and 2 deletions.
  1. +2 −2 src/app/vertextool/qgsvertextool.cpp
  2. +3 −0 tests/src/app/testqgsvertextool.cpp
@@ -475,14 +475,14 @@ void QgsVertexTool::cadCanvasReleaseEvent( QgsMapMouseEvent *e )

mNewVertexFromDoubleClick.reset();

// dragging of edges and double clicking on edges to add vertex are slightly overlapping
// dragging of edges and double-clicking on edges to add vertex are slightly overlapping
// so we need to cancel edge moving before we start dragging new vertex
stopDragging();
startDraggingAddVertex( m );

if ( e->modifiers() & Qt::ShiftModifier )
{
// if this was shift + double click, immediately place the vertex
// if this was shift + double-click, immediately place the vertex
moveVertex( m.point(), &m );
// force update of rubber bands
mouseMoveNotDragging( e );
@@ -547,6 +547,9 @@ void TestQgsVertexTool::testMoveMultipleVertices()
mouseClick( 1, 1, Qt::LeftButton );
mouseClick( 0, 0, Qt::LeftButton );

// extra click away from everything to clear the selection
mouseClick( 8, 8, Qt::LeftButton );

QCOMPARE( mLayerLine->undoStack()->index(), 2 );
QCOMPARE( mLayerLine->getFeature( mFidLineF1 ).geometry(), QgsGeometry::fromWkt( "LINESTRING(2 1, 0 0, 0 2)" ) );

0 comments on commit 36e0233

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