Skip to content
Permalink
Browse files

Correctly add newly created annotations to manager

  • Loading branch information
nyalldawson committed Jan 30, 2017
1 parent ad184cd commit 5584c5312b553dceb7452769f9366bca81fa2316
Showing with 1 addition and 3 deletions.
  1. +1 −3 src/app/qgsmaptoolannotation.cpp
@@ -127,9 +127,7 @@ void QgsMapToolAnnotation::canvasPressEvent( QgsMapMouseEvent* e )
e->posF().y() / mCanvas->height() ) );
annotation->setFrameSize( QSizeF( 200, 100 ) );

QgsMapCanvasAnnotationItem* canvasItem = new QgsMapCanvasAnnotationItem( annotation, mCanvas );
canvasItem->setSelected( true );
QgsProject::instance()->setDirty( true );
QgsProject::instance()->annotationManager()->addAnnotation( annotation );
}
}
}

0 comments on commit 5584c53

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