From e5b0529b91445c70d0584e2d36195012849481ed Mon Sep 17 00:00:00 2001 From: Even Rouault Date: Sat, 29 May 2021 00:27:44 +0200 Subject: [PATCH] [App] Create a map annotation only on left button press event --- src/app/qgsmaptoolannotation.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app/qgsmaptoolannotation.cpp b/src/app/qgsmaptoolannotation.cpp index 39a8994d215e..1601e1a0b955 100644 --- a/src/app/qgsmaptoolannotation.cpp +++ b/src/app/qgsmaptoolannotation.cpp @@ -80,7 +80,7 @@ void QgsMapToolAnnotation::canvasReleaseEvent( QgsMapMouseEvent *e ) void QgsMapToolAnnotation::canvasPressEvent( QgsMapMouseEvent *e ) { - if ( !mCanvas ) + if ( !mCanvas || !( e->buttons() & Qt::LeftButton ) ) { return; }