Skip to content

Commit 16481d2

Browse files
3nidsm-kuhn
authored andcommittedOct 15, 2018
add configuration map to constructors of all tests
1 parent 3817df6 commit 16481d2

File tree

3 files changed

+3
-5
lines changed

3 files changed

+3
-5
lines changed
 

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

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,6 @@ QList<QgsWkbTypes::GeometryType> QgsGeometryIsValidCheck::compatibleGeometryType
3030

3131
QList<QgsSingleGeometryCheckError *> QgsGeometryIsValidCheck::processGeometry( const QgsGeometry &geometry ) const
3232
{
33-
Q_UNUSED( configuration )
34-
3533
QVector<QgsGeometry::Error> errors;
3634

3735
QgsGeometry::ValidationMethod method = QgsGeometry::ValidatorQgisInternal;

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,5 +27,5 @@ bool QgsGeometrySliverPolygonCheck::checkThreshold( double layerToMapUnits, cons
2727
{
2828
return false;
2929
}
30-
return value > mCheckConfiguration.value( QStringLiteral( "thresholdMapUnits" ) ).toDouble(); // the sliver threshold is actually a map unit independent number, just abusing QgsGeometryAreaCheck::mThresholdMapUnits to store it
30+
return value > mThreshold; // the sliver threshold is actually a map unit independent number, just abusing QgsGeometryAreaCheck::mThresholdMapUnits to store it
3131
}

‎src/app/qgsgeometryvalidationservice.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ QgsGeometryValidationService::QgsGeometryValidationService( QgsProject *project
2525
{
2626
connect( project, &QgsProject::layersAdded, this, &QgsGeometryValidationService::onLayersAdded );
2727
// TODO: should not provide a nullptr context
28-
mIsValidGeometryCheck = new QgsIsValidGeometryCheck( nullptr );
28+
mIsValidGeometryCheck = new QgsIsValidGeometryCheck( nullptr, QVariantMap() );
2929
}
3030

3131
QgsGeometryValidationService::~QgsGeometryValidationService()
@@ -89,6 +89,6 @@ void QgsGeometryValidationService::processFeature( QgsVectorLayer *layer, QgsFea
8989

9090
QgsFeature feature = layer->getFeature( fid );
9191
// TODO: this is a bit hardcore
92-
const auto errors = mIsValidGeometryCheck->processGeometry( feature.geometry(), QVariantMap() );
92+
const auto errors = mIsValidGeometryCheck->processGeometry( feature.geometry() );
9393
// emit geometryCheckCompleted( layer, fid, errors );
9494
}

0 commit comments

Comments
 (0)