Skip to content

Commit

Permalink
QString fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Feb 4, 2025
1 parent 638e6a9 commit 0520d1f
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion src/3d/qgs3dsceneexporter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -469,7 +469,7 @@ void Qgs3DSceneExporter::parseMeshTile( QgsTerrainTileEntity *tileEntity, const
{
QString objectNamePrefix = layerName;
if ( objectNamePrefix != QString() )
objectNamePrefix += QStringLiteral( "_" );
objectNamePrefix += QLatin1Char( '_' );

const QList<Qt3DRender::QGeometryRenderer *> renderers = tileEntity->findChildren<Qt3DRender::QGeometryRenderer *>();
for ( Qt3DRender::QGeometryRenderer *renderer : renderers )
Expand Down
2 changes: 1 addition & 1 deletion src/3d/symbols/qgspoint3dsymbol.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ void QgsPoint3DSymbol::setDefaultPropertiesFromLayer( const QgsVectorLayer *laye

Qgis::Point3DShape QgsPoint3DSymbol::shapeFromString( const QString &shape )
{
if ( shape == QStringLiteral( "sphere" ) )
if ( shape == QLatin1String( "sphere" ) )
return Qgis::Point3DShape::Sphere;
else if ( shape == QLatin1String( "cone" ) )
return Qgis::Point3DShape::Cone;
Expand Down
2 changes: 1 addition & 1 deletion src/core/vectortile/qgsmapboxglstyleconverter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1716,7 +1716,7 @@ void QgsMapBoxGlStyleConverter::parseSymbolLayer( const QVariantMap &jsonLayer,
case QMetaType::Type::QVariantMap:
{
QVariantMap rotateMap = jsonTextRotate.toMap();
if ( rotateMap.contains( QStringLiteral( "property" ) ) && rotateMap[QStringLiteral( "type" )].toString() == QStringLiteral( "identity" ) )
if ( rotateMap.contains( QStringLiteral( "property" ) ) && rotateMap[QStringLiteral( "type" )].toString() == QLatin1String( "identity" ) )
{
const QgsProperty property = QgsProperty::fromExpression( rotateMap[QStringLiteral( "property" )].toString() );
ddLabelProperties.setProperty( QgsPalLayerSettings::Property::LabelRotation, property );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2588,7 +2588,7 @@ bool QgsPostgresRasterProviderMetadata::saveStyle( const QString &uri, const QSt
.arg( QgsPostgresConn::quotedValue( dsUri.database() ) )
.arg( QgsPostgresConn::quotedValue( dsUri.schema() ) )
.arg( QgsPostgresConn::quotedValue( dsUri.table() ) )
.arg( QStringLiteral( "NULL" ) )
.arg( QLatin1String( "NULL" ) )
.arg( QgsPostgresConn::quotedValue( styleName.isEmpty() ? dsUri.table() : styleName ) )
.arg( useAsDefault ? "true" : "false" )
.arg( QgsPostgresConn::quotedValue( styleDescription.isEmpty() ? QDateTime::currentDateTime().toString() : styleDescription ) )
Expand Down
2 changes: 1 addition & 1 deletion src/server/qgsserverapiutils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ QList<QgsMapLayerServerProperties::WmsDimensionInfo> QgsServerApiUtils::temporal
// Filter only date and time
dimensions.erase( std::remove_if( dimensions.begin(), dimensions.end(), []( QgsMapLayerServerProperties::WmsDimensionInfo &dim ) {
return dim.name.toLower() != QStringLiteral( "time" )
&& dim.name.toLower() != QStringLiteral( "date" );
&& dim.name.toLower() != QLatin1String( "date" );
} ),
dimensions.end() );

Expand Down
4 changes: 2 additions & 2 deletions src/server/services/wfs/qgswfsdescribefeaturetype.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ namespace QgsWfs
}

const QgsEditorWidgetSetup setup = field.editorWidgetSetup();
if ( setup.type() == QStringLiteral( "DateTime" ) )
if ( setup.type() == QLatin1String( "DateTime" ) )
{
// Get editor widget setup config
const QVariantMap config = setup.config();
Expand All @@ -171,7 +171,7 @@ namespace QgsWfs
else if ( fieldFormat == QgsDateTimeFieldFormatter::QT_ISO_FORMAT )
fieldType = QStringLiteral( "dateTime" );
}
else if ( setup.type() == QStringLiteral( "Range" ) )
else if ( setup.type() == QLatin1String( "Range" ) )
{
const QVariantMap config = setup.config();
if ( config.contains( QStringLiteral( "Precision" ) ) )
Expand Down
4 changes: 2 additions & 2 deletions src/server/services/wfs/qgswfsgetfeature.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1629,7 +1629,7 @@ namespace QgsWfs
if ( QgsVariantUtils::isNull( value ) )
return QString();

if ( setup.type() == QStringLiteral( "DateTime" ) )
if ( setup.type() == QLatin1String( "DateTime" ) )
{
// For time fields use const TIME_FORMAT
if ( value.userType() == QMetaType::Type::QTime )
Expand Down Expand Up @@ -1658,7 +1658,7 @@ namespace QgsWfs
// else provide the value as string
return value.toString();
}
else if ( setup.type() == QStringLiteral( "Range" ) )
else if ( setup.type() == QLatin1String( "Range" ) )
{
const QVariantMap config = setup.config();
if ( config.contains( QStringLiteral( "Precision" ) ) )
Expand Down

0 comments on commit 0520d1f

Please sign in to comment.