[QGIS Commit] r15577 - trunk/qgis/python/plugins/GdalTools/tools
svn_qgis at osgeo.org
svn_qgis at osgeo.org
Tue Mar 22 21:14:41 EDT 2011
Author: brushtyler
Date: 2011-03-22 18:14:41 -0700 (Tue, 22 Mar 2011)
New Revision: 15577
Modified:
trunk/qgis/python/plugins/GdalTools/tools/doContour.py
trunk/qgis/python/plugins/GdalTools/tools/doPolygonize.py
trunk/qgis/python/plugins/GdalTools/tools/doTileIndex.py
Log:
fix error when output file is not created
Modified: trunk/qgis/python/plugins/GdalTools/tools/doContour.py
===================================================================
--- trunk/qgis/python/plugins/GdalTools/tools/doContour.py 2011-03-23 01:01:18 UTC (rev 15576)
+++ trunk/qgis/python/plugins/GdalTools/tools/doContour.py 2011-03-23 01:14:41 UTC (rev 15577)
@@ -80,6 +80,6 @@
def addLayerIntoCanvas(self, fileInfo):
vl = self.iface.addVectorLayer(fileInfo.filePath(), "contour", "ogr")
- if vl.isValid():
+ if vl != None and vl.isValid():
if hasattr(self, 'lastEncoding'):
vl.setProviderEncoding(self.lastEncoding)
Modified: trunk/qgis/python/plugins/GdalTools/tools/doPolygonize.py
===================================================================
--- trunk/qgis/python/plugins/GdalTools/tools/doPolygonize.py 2011-03-23 01:01:18 UTC (rev 15576)
+++ trunk/qgis/python/plugins/GdalTools/tools/doPolygonize.py 2011-03-23 01:14:41 UTC (rev 15577)
@@ -81,6 +81,6 @@
def addLayerIntoCanvas(self, fileInfo):
vl = self.iface.addVectorLayer(fileInfo.filePath(), fileInfo.baseName(), "ogr")
- if vl.isValid():
+ if vl != None and vl.isValid():
if hasattr(self, 'lastEncoding'):
vl.setProviderEncoding(self.lastEncoding)
Modified: trunk/qgis/python/plugins/GdalTools/tools/doTileIndex.py
===================================================================
--- trunk/qgis/python/plugins/GdalTools/tools/doTileIndex.py 2011-03-23 01:01:18 UTC (rev 15576)
+++ trunk/qgis/python/plugins/GdalTools/tools/doTileIndex.py 2011-03-23 01:14:41 UTC (rev 15577)
@@ -69,6 +69,6 @@
def addLayerIntoCanvas( self, fileInfo ):
vl = self.iface.addVectorLayer( fileInfo.filePath(), fileInfo.baseName(), "ogr" )
- if vl.isValid():
+ if vl != None and vl.isValid():
if hasattr( self, 'lastEncoding' ):
vl.setProviderEncoding( self.lastEncoding )
More information about the QGIS-commit
mailing list