Skip to content

Commit

Permalink
don't try to refresh the layer extent after deletion of features, if
Browse files Browse the repository at this point in the history
useEstimatedMetadata is enabled (tradeoff for large layers)
  • Loading branch information
jef-n committed Feb 22, 2016
1 parent 5b46f48 commit f1e1559
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/core/qgsvectorlayer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -825,7 +825,9 @@ QgsRectangle QgsVectorLayer::extent()
return rect;
}

if ( !mEditBuffer || ( mEditBuffer->mDeletedFeatureIds.isEmpty() && mEditBuffer->mChangedGeometries.isEmpty() ) )
if ( !mEditBuffer ||
( mEditBuffer->mDeletedFeatureIds.isEmpty() && mEditBuffer->mChangedGeometries.isEmpty() ) ||
QgsDataSourceURI( mDataProvider->dataSourceUri() ).useEstimatedMetadata() )
{
mDataProvider->updateExtents();

Expand Down

0 comments on commit f1e1559

Please sign in to comment.