Skip to content
Permalink
Browse files
Fix feature counting
  • Loading branch information
m-kuhn committed May 11, 2017
1 parent a6800e9 commit 3e88e8e
Showing 1 changed file with 1 addition and 2 deletions.
@@ -703,8 +703,7 @@ bool QgsVectorLayer::countSymbolFeatures()
if ( !mFeatureCounter )
{
mFeatureCounter = new QgsVectorLayerFeatureCounter( this );
connect( mFeatureCounter, &QgsVectorLayerFeatureCounter::symbolsCounted, this, &QgsVectorLayer::onSymbolsCounted );
connect( mFeatureCounter, &QgsTask::taskCompleted, [ = ]() { mFeatureCounter = nullptr; } );
connect( mFeatureCounter, &QgsTask::taskCompleted, [ = ]() { onSymbolsCounted(); mFeatureCounter = nullptr; } );
connect( mFeatureCounter, &QgsTask::taskTerminated, [ = ]() { mFeatureCounter = nullptr; } );

QgsApplication::taskManager()->addTask( mFeatureCounter );

0 comments on commit 3e88e8e

Please sign in to comment.