Skip to content

Commit

Permalink
QString fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Jan 28, 2021
1 parent 9e2b832 commit 02610c9
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 10 deletions.
4 changes: 2 additions & 2 deletions src/3d/qgs3dmapsettings.cpp
Expand Up @@ -103,9 +103,9 @@ void Qgs3DMapSettings::readXml( const QDomElement &elem, const QgsReadWriteConte
mFieldOfView = elemCamera.attribute( QStringLiteral( "field-of-view" ), QStringLiteral( "45" ) ).toFloat();
mProjectionType = static_cast< Qt3DRender::QCameraLens::ProjectionType >( elemCamera.attribute( QStringLiteral( "projection-type" ), QStringLiteral( "1" ) ).toInt() );
QString cameraNavigationMode = elemCamera.attribute( QStringLiteral( "camera-navigation-mode" ), QStringLiteral( "basic-navigation" ) );
if ( cameraNavigationMode == QStringLiteral( "terrain-based-navigation" ) )
if ( cameraNavigationMode == QLatin1String( "terrain-based-navigation" ) )
mCameraNavigationMode = QgsCameraController::NavigationMode::TerrainBasedNavigation;
else if ( cameraNavigationMode == QStringLiteral( "walk-navigation" ) )
else if ( cameraNavigationMode == QLatin1String( "walk-navigation" ) )
mCameraNavigationMode = QgsCameraController::NavigationMode::WalkNavigation;
mCameraMovementSpeed = elemCamera.attribute( QStringLiteral( "camera-movement-speed" ), QStringLiteral( "5.0" ) ).toDouble();
}
Expand Down
2 changes: 1 addition & 1 deletion src/app/3d/qgspointcloud3dsymbolwidget.cpp
Expand Up @@ -464,7 +464,7 @@ void QgsPointCloud3DSymbolWidget::rampAttributeChanged()
mProviderMax = std::numeric_limits< double >::quiet_NaN();
}

if ( mRenderingParameterComboBox->currentAttribute() == QStringLiteral( "Z" ) )
if ( mRenderingParameterComboBox->currentAttribute() == QLatin1String( "Z" ) )
{
const double zScale = static_cast< const QgsPointCloudLayerElevationProperties * >( mLayer->elevationProperties() )->zScale();
const double zOffset = static_cast< const QgsPointCloudLayerElevationProperties * >( mLayer->elevationProperties() )->zOffset();
Expand Down
8 changes: 4 additions & 4 deletions src/app/qgsrelationmanagerdialog.cpp
Expand Up @@ -107,8 +107,8 @@ int QgsRelationManagerDialog::addPolymorphicRelation( const QgsPolymorphicRelati
{
if ( i != 0 )
{
referencingFields += QStringLiteral( ", " );
referencedFields += QStringLiteral( ", " );
referencingFields += QLatin1String( ", " );
referencedFields += QLatin1String( ", " );
}

referencingFields += polyRel.fieldPairs().at( i ).referencingField();
Expand Down Expand Up @@ -346,7 +346,7 @@ QList< QgsRelation > QgsRelationManagerDialog::relations()
{
QTreeWidgetItem *item = mRelationsTree->topLevelItem( i );

if ( item->data( 0, Qt::UserRole ).typeName() != QStringLiteral( "QgsRelation" ) )
if ( item->data( 0, Qt::UserRole ).typeName() != QLatin1String( "QgsRelation" ) )
continue;

QgsRelation relation = item->data( 0, Qt::UserRole ).value<QgsRelation>();
Expand All @@ -368,7 +368,7 @@ QList< QgsPolymorphicRelation > QgsRelationManagerDialog::polymorphicRelations()
{
QTreeWidgetItem *item = mRelationsTree->topLevelItem( i );

if ( item->data( 0, Qt::UserRole ).typeName() != QStringLiteral( "QgsPolymorphicRelation" ) )
if ( item->data( 0, Qt::UserRole ).typeName() != QLatin1String( "QgsPolymorphicRelation" ) )
continue;

QgsPolymorphicRelation relation = item->data( 0, Qt::UserRole ).value<QgsPolymorphicRelation>();
Expand Down
2 changes: 1 addition & 1 deletion src/providers/mssql/qgsmssqlconnection.cpp
Expand Up @@ -560,7 +560,7 @@ QString QgsMssqlConnection::buildQueryForTables( bool allowTablesWithNoGeometry,
QString query( QStringLiteral( "SELECT " ) );
if ( geometryColumnOnly )
{
query += QStringLiteral( "f_table_schema, f_table_name, f_geometry_column, srid, geometry_type, 0 FROM geometry_columns" );
query += QLatin1String( "f_table_schema, f_table_name, f_geometry_column, srid, geometry_type, 0 FROM geometry_columns" );
if ( !notSelectedSchemas.isEmpty() )
query += QStringLiteral( " WHERE f_table_schema NOT IN %1" ).arg( notSelectedSchemas );
}
Expand Down
2 changes: 1 addition & 1 deletion src/providers/postgres/qgspostgresconn.cpp
Expand Up @@ -248,7 +248,7 @@ QgsPostgresConn::QgsPostgresConn( const QString &conninfo, bool readOnly, bool s
connectString += QStringLiteral( " connect_timeout=%1" ).arg( timeout );
}

connectString += QStringLiteral( " client_encoding='UTF-8'" );
connectString += QLatin1String( " client_encoding='UTF-8'" );
};
addDefaultTimeoutAndClientEncoding( expandedConnectionInfo );

Expand Down
2 changes: 1 addition & 1 deletion tests/src/analysis/testqgsprocessingalgs.cpp
Expand Up @@ -6485,7 +6485,7 @@ void TestQgsProcessingAlgs::fileDownloader()
results = alg->run( parameters, *context, &feedback, &ok );
QVERIFY( ok );
// verify that temporary outputs have the URL file extension appended
QVERIFY( results.value( QStringLiteral( "OUTPUT" ) ).toString().endsWith( QStringLiteral( ".txt" ) ) );
QVERIFY( results.value( QStringLiteral( "OUTPUT" ) ).toString().endsWith( QLatin1String( ".txt" ) ) );
}

void TestQgsProcessingAlgs::exportMeshTimeSeries()
Expand Down

0 comments on commit 02610c9

Please sign in to comment.