Skip to content

Commit

Permalink
A bit less nesting
Browse files Browse the repository at this point in the history
  • Loading branch information
m-kuhn committed Sep 24, 2018
1 parent f9f683d commit 88ccb88
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions src/gui/qgsmapcanvasannotationitem.cpp
Expand Up @@ -124,16 +124,13 @@ void QgsMapCanvasAnnotationItem::onCanvasLayersChanged()
{
setVisible( false );
}
else if ( !mAnnotation->mapLayer() )
{
setVisible( true );
}
else
{
if ( !mAnnotation->mapLayer() )
{
setVisible( true );
}
else
{
setVisible( mMapCanvas->mapSettings().layers().contains( mAnnotation->mapLayer() ) );
}
setVisible( mMapCanvas->mapSettings().layers().contains( mAnnotation->mapLayer() ) );
}
}

Expand Down

0 comments on commit 88ccb88

Please sign in to comment.