Skip to content
Permalink
Browse files

[Geometry checker] Only add to feature pool spatial indices features …

…which are to be processed
  • Loading branch information
manisandro committed Oct 19, 2017
1 parent e00f767 commit e089b3ba6a941cbaee33707f2f174c4911c9159c
@@ -48,7 +48,7 @@ QgsFeaturePool::QgsFeaturePool( QgsVectorLayer *layer, double layerToMapUnits, c
QgsFeatureIterator it = layer->getFeatures( req );
while ( it.nextFeature( feature ) )
{
if ( feature.geometry() )
if ( mFeatureIds.contains( feature.id() ) && feature.geometry() )
{
mIndex.insertFeature( feature );
}
@@ -166,11 +166,6 @@ bool QgsGeometryChecker::fixError( QgsGeometryCheckError *error, int method, boo
QgsFeaturePool *featurePool = mContext->featurePools[layerId];
QgsCoordinateTransform t = QgsCoordinateTransformCache::instance()->transform( mContext->mapCrs, featurePool->getLayer()->crs().authid() );
recheckAreaFeatures[layerId] = featurePool->getIntersects( t.transform( recheckArea ) );
// If only selected features were checked, confine the recheck areas to the selected features
if ( featurePool->getSelectedOnly() )
{
recheckAreaFeatures[layerId] = recheckAreaFeatures[layerId].intersect( featurePool->getLayer()->selectedFeatureIds() );
}
}

// Recheck feature / changed area to detect new errors

0 comments on commit e089b3b

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