Skip to content

Commit

Permalink
Small cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
merydian committed Jul 3, 2024
1 parent a7365ed commit e298ec3
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions src/core/providers/arcgis/qgsarcgisrestutils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -964,8 +964,6 @@ QgsFeatureRenderer *QgsArcGisRestUtils::convertRenderer( const QVariantMap &rend
if (esriMode.isEmpty()){
const QString esriMode = rendererData.value( QStringLiteral( "classificationMethod" ) ).toString();
}


if (esriMode == QString("esriClassifyDefinedInterval")){
QgsClassificationFixedInterval* method = new QgsClassificationFixedInterval();
graduatedRenderer->setClassificationMethod(method);
Expand Down Expand Up @@ -1001,12 +999,11 @@ QgsFeatureRenderer *QgsArcGisRestUtils::convertRenderer( const QVariantMap &rend
symbolData = classBreakInfos.at( 0 ).toMap().value( QStringLiteral( "symbol" ) ).toMap();
}
std::unique_ptr< QgsSymbol > symbol( QgsArcGisRestUtils::convertSymbol( symbolData ) );
double transparency = rendererData.value( QStringLiteral( "transparency" ) ).toFloat();

double opacity = (100.0 - transparency) / 100.0;

if ( !symbol )
return nullptr;

double transparency = rendererData.value( QStringLiteral( "transparency" ) ).toFloat();
double opacity = (100.0 - transparency) / 100.0;
else {
symbol->setOpacity(opacity);
graduatedRenderer->setSourceSymbol( symbol.release() );
Expand Down

0 comments on commit e298ec3

Please sign in to comment.