Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Restrict input type for zonal statistics to gdal rasters for now (swi…
…tch to use QgsRasterDataProvider in the mid term)
  • Loading branch information
mhugent committed Mar 18, 2012
1 parent 9f57650 commit c9bbcd8
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/plugins/zonal_statistics/qgszonalstatisticsdialog.cpp
Expand Up @@ -61,7 +61,11 @@ void QgsZonalStatisticsDialog::insertAvailableLayers()
QgsRasterLayer* rl = dynamic_cast<QgsRasterLayer*>( layer_it.value() );
if ( rl )
{
mRasterLayerComboBox->addItem( rl->name(), QVariant( rl->source() ) );
QgsRasterDataProvider* rp = rl->dataProvider();
if ( rp && rp->name() == "gdal" )
{
mRasterLayerComboBox->addItem( rl->name(), QVariant( rl->source() ) );
}
}
else
{
Expand Down

0 comments on commit c9bbcd8

Please sign in to comment.