Skip to content
Permalink
Browse files

Tweak legend expression cache invalidation

  • Loading branch information
nyalldawson committed Jun 17, 2020
1 parent 5d98ad1 commit 2e3364234c393c82748fee319bf062b50ec5dcc4
Showing with 2 additions and 2 deletions.
  1. +1 −1 src/core/layout/qgslayoutitemlegend.cpp
  2. +1 −1 src/gui/layout/qgslayoutlegendwidget.cpp
@@ -867,7 +867,6 @@ void QgsLayoutItemLegend::updateFilterByMap( bool redraw )
// the actual update will take place before the redraw.
// This is to avoid multiple calls to the filter
mFilterAskedForUpdate = true;
clearLegendCachedData();

if ( redraw )
update();
@@ -915,6 +914,7 @@ void QgsLayoutItemLegend::doUpdateFilterByMap()
else
mLegendModel->setLegendFilterByMap( nullptr );

clearLegendCachedData();
mForceResize = true;
}

@@ -1131,7 +1131,7 @@ void QgsLayoutLegendWidget::mLayerExpressionButton_clicked()
layerNode->setLabelExpression( expressiondialog.expressionText() );

mLegend->beginCommand( tr( "Update Legend" ) );
mLegend->updateLegend();
mLegend->refresh();
mLegend->adjustBoxSize();
mLegend->endCommand();
}

0 comments on commit 2e33642

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