Skip to content

Commit

Permalink
aligend to use QLatin1String to have a better portability to qgis3
Browse files Browse the repository at this point in the history
  • Loading branch information
luipir committed Oct 9, 2017
1 parent b3ea17f commit 60485ac
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/core/layertree/qgslayertreemodel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ QVariant QgsLayerTreeModel::data( const QModelIndex &index, int role ) const
if ( testFlag( ShowRasterPreviewIcon ) )
{
QgsRasterLayer* rlayer = qobject_cast<QgsRasterLayer *>( layer );
if ( rlayer->providerType() == "wms" )
if ( rlayer->providerType() == QLatin1String( "wms" ) )
return QgsLayerItem::iconRaster();
return QIcon( QPixmap::fromImage( rlayer->previewAsImage( QSize( 32, 32 ) ) ) );
}
Expand Down

0 comments on commit 60485ac

Please sign in to comment.