Skip to content

Commit e089b3b

Browse files
committedOct 23, 2017
[Geometry checker] Only add to feature pool spatial indices features which are to be processed
1 parent e00f767 commit e089b3b

File tree

2 files changed

+1
-6
lines changed

2 files changed

+1
-6
lines changed
 

‎src/analysis/vector/geometry_checker/qgsfeaturepool.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ QgsFeaturePool::QgsFeaturePool( QgsVectorLayer *layer, double layerToMapUnits, c
4848
QgsFeatureIterator it = layer->getFeatures( req );
4949
while ( it.nextFeature( feature ) )
5050
{
51-
if ( feature.geometry() )
51+
if ( mFeatureIds.contains( feature.id() ) && feature.geometry() )
5252
{
5353
mIndex.insertFeature( feature );
5454
}

‎src/analysis/vector/geometry_checker/qgsgeometrychecker.cpp

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -166,11 +166,6 @@ bool QgsGeometryChecker::fixError( QgsGeometryCheckError *error, int method, boo
166166
QgsFeaturePool *featurePool = mContext->featurePools[layerId];
167167
QgsCoordinateTransform t = QgsCoordinateTransformCache::instance()->transform( mContext->mapCrs, featurePool->getLayer()->crs().authid() );
168168
recheckAreaFeatures[layerId] = featurePool->getIntersects( t.transform( recheckArea ) );
169-
// If only selected features were checked, confine the recheck areas to the selected features
170-
if ( featurePool->getSelectedOnly() )
171-
{
172-
recheckAreaFeatures[layerId] = recheckAreaFeatures[layerId].intersect( featurePool->getLayer()->selectedFeatureIds() );
173-
}
174169
}
175170

176171
// Recheck feature / changed area to detect new errors

0 commit comments

Comments
 (0)
Please sign in to comment.