Skip to content

Commit

Permalink
Ftools-Sum Line length - Fix progress bar
Browse files Browse the repository at this point in the history
  • Loading branch information
vinayan committed Jun 1, 2013
1 parent a39b78b commit ba4a3cc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions python/plugins/fTools/tools/doSumLines.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,8 @@ def compute(self, inPoly, inLns, inField, outPath, progressBar):
inGeom = QgsGeometry()
outGeom = QgsGeometry()
distArea = QgsDistanceArea()
start = 15.00
add = 85.00 / polyProvider.featureCount()
start = 0.00
add = 100.00 / polyProvider.featureCount()
check = QFile(self.shapefileName)
if check.exists():
if not QgsVectorFileWriter.deleteShapeFile(self.shapefileName):
Expand Down Expand Up @@ -142,5 +142,5 @@ def compute(self, inPoly, inLns, inField, outPath, progressBar):
#outFeat.setAttribute(index, QVariant(length))
writer.addFeature(outFeat)
start = start + 1
progressBar.setValue(start)
progressBar.setValue( start * (add))
del writer

0 comments on commit ba4a3cc

Please sign in to comment.