Skip to content

Commit

Permalink
[fTools] enable OK button when error occurs (fix #13104)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexbruy committed Jan 13, 2016
1 parent 14c858a commit 3d44e1f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions python/plugins/fTools/tools/doSimplify.py
Expand Up @@ -103,6 +103,7 @@ def accept(self):
if not QgsVectorFileWriter.deleteShapeFile(outFileName):
QMessageBox.warning(self, self.tr("Delete error"),
self.tr("Can't delete file %s") % (outFileName))
self.btnOk.setEnabled(False)
return

self.workThread = GeomThread(self.myFunction, vLayer, self.chkUseSelection.isChecked(),
Expand All @@ -115,6 +116,7 @@ def accept(self):
"attribute tables are closed. Continue?"),
QMessageBox.Yes | QMessageBox.No)
if res == QMessageBox.No:
self.btnOk.setEnabled(False)
return

self.workThread = GeomThread(self.myFunction, vLayer, self.chkUseSelection.isChecked(),
Expand Down

0 comments on commit 3d44e1f

Please sign in to comment.