Skip to content

Commit

Permalink
Don't show map tips for layers with scale range visibility which are …
Browse files Browse the repository at this point in the history
…out of the range

(cherry picked from commit 32af963)
  • Loading branch information
nyalldawson committed Jan 15, 2021
1 parent 5a9cd1f commit 0db8970
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/gui/qgsmaptip.cpp
Expand Up @@ -190,6 +190,11 @@ QString QgsMapTip::fetchFeature( QgsMapLayer *layer, QgsPointXY &mapPosition, Qg
if ( !vlayer || !vlayer->isSpatial() )
return QString();

if ( !layer->isInScaleRange( mapCanvas->mapSettings().scale() ) )
{
return QString();
}

double searchRadius = QgsMapTool::searchRadiusMU( mapCanvas );

QgsRectangle r;
Expand Down

0 comments on commit 0db8970

Please sign in to comment.