Skip to content

Commit f44200e

Browse files
committed
Trying to understand what's wrong on travis...
1 parent 8e7bb3b commit f44200e

File tree

1 file changed

+11
-4
lines changed

1 file changed

+11
-4
lines changed

src/app/nodetool/qgsnodetool2.cpp

+11-4
Original file line numberDiff line numberDiff line change
@@ -314,21 +314,25 @@ void QgsNodeTool2::cadCanvasReleaseEvent( QgsMapMouseEvent *e )
314314
}
315315
else // selection rect is not being dragged
316316
{
317+
qDebug( "release: no selection rect!" );
317318
if ( e->button() == Qt::LeftButton )
318319
{
319320
// accepting action
320321
if ( mDraggingVertex )
321322
{
322323
QgsPointLocator::Match match = e->mapPointMatch();
324+
qDebug( "release: move vertex" );
323325
moveVertex( e->mapPoint(), &match );
324326
}
325327
else if ( mDraggingEdge )
326328
{
327329
// do not use e.mapPoint() as it may be snapped
330+
qDebug( "release: move edge" );
328331
moveEdge( toMapCoordinates( e->pos() ) );
329332
}
330333
else
331334
{
335+
qDebug( "release: start dragging" );
332336
startDragging( e );
333337
}
334338
}
@@ -1016,11 +1020,12 @@ void QgsNodeTool2::moveVertex( const QgsPoint &mapPoint, const QgsPointLocator::
10161020
stopDragging();
10171021

10181022
QgsPoint layerPoint = matchToLayerPoint( dragLayer, mapPoint, mapPointMatch );
1023+
qDebug( "layer pt: %f,%f", layerPoint.x(), layerPoint.y() );
10191024

10201025
QgsVertexId vid;
10211026
if ( !geom.vertexIdFromVertexNr( dragVertexId, vid ) )
10221027
{
1023-
QgsDebugMsg( "invalid vertex index" );
1028+
qDebug( "invalid vertex index" );
10241029
return;
10251030
}
10261031

@@ -1034,15 +1039,15 @@ void QgsNodeTool2::moveVertex( const QgsPoint &mapPoint, const QgsPointLocator::
10341039

10351040
if ( !geomTmp->insertVertex( vid, QgsPointV2( layerPoint ) ) )
10361041
{
1037-
QgsDebugMsg( "append vertex failed!" );
1042+
qDebug( "append vertex failed!" );
10381043
return;
10391044
}
10401045
}
10411046
else
10421047
{
10431048
if ( !geomTmp->moveVertex( vid, QgsPointV2( layerPoint ) ) )
10441049
{
1045-
QgsDebugMsg( "move vertex failed!" );
1050+
qDebug( "move vertex failed!" );
10461051
return;
10471052
}
10481053
}
@@ -1070,7 +1075,7 @@ void QgsNodeTool2::moveVertex( const QgsPoint &mapPoint, const QgsPointLocator::
10701075

10711076
if ( !topoGeom.moveVertex( point.x(), point.y(), topo.vertexId ) )
10721077
{
1073-
QgsDebugMsg( "[topo] move vertex failed!" );
1078+
qDebug( "[topo] move vertex failed!" );
10741079
continue;
10751080
}
10761081
edits[topo.layer][topo.fid] = topoGeom;
@@ -1080,6 +1085,8 @@ void QgsNodeTool2::moveVertex( const QgsPoint &mapPoint, const QgsPointLocator::
10801085

10811086
// TODO: add topological points: when moving vertex - if snapped to something
10821087

1088+
qDebug( "writing changes now" );
1089+
10831090
// do the changes to layers
10841091
QHash<QgsVectorLayer*, QHash<QgsFeatureId, QgsGeometry> >::iterator it = edits.begin();
10851092
for ( ; it != edits.end(); ++it )

0 commit comments

Comments
 (0)