Showing with 4 additions and 1 deletion.
  1. +4 −1 python/plugins/sextante/gui/NumberInputDialog.py
5 changes: 4 additions & 1 deletion python/plugins/sextante/gui/NumberInputDialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,10 @@ def fillTree(self):
layers = QGisLayers.getRasterLayers()
for layer in layers:
for i in range(layer.bandCount()):
stats = layer.bandStatistics(i)
if QGis.QGIS_VERSION_INT >= 10900:
stats = layer.dataProvider().bandStatistics(i+1)
else:
stats = layer.bandStatistics(i)
layerItem = QtGui.QTreeWidgetItem()
layerItem.setText(0, unicode(layer.name()))
layerItem.addChild(TreeValueItem("Mean", stats.mean))
Expand Down