X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FTools%2FYamsPlug%2FmonViewText.py;h=c1e90255b6e7a8bd3704d0acc589401956a25875;hb=e18c7bf13376458fb15a7866f246fe376702c9fb;hp=426467ef4351d3380656ef528ee70de52fc34016;hpb=0f0bf7c72871fc015ec1637067cd1d58e61395b9;p=modules%2Fsmesh.git diff --git a/src/Tools/YamsPlug/monViewText.py b/src/Tools/YamsPlug/monViewText.py index 426467ef4..c1e90255b 100644 --- a/src/Tools/YamsPlug/monViewText.py +++ b/src/Tools/YamsPlug/monViewText.py @@ -53,11 +53,14 @@ class MonViewText(Ui_ViewExe, QDialog): self.monExe.readyReadStandardOutput.connect( self.readFromStdOut ) self.monExe.readyReadStandardError.connect( self.readFromStdErr ) + self.monExe.finished.connect( self.finished ) cmds = '' ext = '' if sys.platform == "win32": - cmds += 'delete %s\n' % self.parent().fichierOut + if os.path.exists(self.parent().fichierOut): + cmds += 'del %s\n' % self.parent().fichierOut + ext = '.bat' else: cmds += '#!/bin/bash\n' cmds += 'pwd\n' @@ -108,12 +111,12 @@ class MonViewText(Ui_ViewExe, QDialog): def readFromStdOut(self) : a=self.monExe.readAllStandardOutput() - aa=unicode(a.data(),len(a)) - self.TB_Exe.append(aa) - if "END_OF_MGSurfOpt" in aa: - self.parent().enregistreResultat() - self.enregistreResultatsDone=True - #self.theClose() + aa=unicode(a.data()) + self.TB_Exe.append(aa) + + def finished(self): + self.parent().enregistreResultat() + self.enregistreResultatsDone=True def theClose(self): if not self.enregistreResultatsDone: