Skip to content

Commit 9a9cf3c

Browse files
committed
Shapes drawing with 3 points are no longer frozen when a left click is
made for the 3rd point.
1 parent 6a1bacf commit 9a9cf3c

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

src/app/qgsmaptoolcircle3points.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,8 @@ void QgsMapToolCircle3Points::cadCanvasReleaseEvent( QgsMapMouseEvent *e )
3636

3737
if ( e->button() == Qt::LeftButton )
3838
{
39-
mPoints.append( mapPoint );
39+
if ( mPoints.size() < 2 )
40+
mPoints.append( mapPoint );
4041

4142
if ( !mPoints.isEmpty() )
4243
{

src/app/qgsmaptoolellipsecenter2points.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,9 @@ void QgsMapToolEllipseCenter2Points::cadCanvasReleaseEvent( QgsMapMouseEvent *e
3636

3737
if ( e->button() == Qt::LeftButton )
3838
{
39-
mPoints.append( mapPoint );
39+
40+
if ( mPoints.size() < 2 )
41+
mPoints.append( mapPoint );
4042

4143
if ( !mPoints.isEmpty() )
4244
{

0 commit comments

Comments
 (0)