52 def stopProcesses(self): |
52 def stopProcesses(self): |
53 """ |
53 """ |
54 Public slot to stop the diff processes. |
54 Public slot to stop the diff processes. |
55 """ |
55 """ |
56 for process in [self.process, self.process2]: |
56 for process in [self.process, self.process2]: |
57 if process is not None and \ |
57 if ( |
58 process.state() != QProcess.NotRunning: |
58 process is not None and |
|
59 process.state() != QProcess.NotRunning |
|
60 ): |
59 process.terminate() |
61 process.terminate() |
60 QTimer.singleShot(2000, process.kill) |
62 QTimer.singleShot(2000, process.kill) |
61 process.waitForFinished(3000) |
63 process.waitForFinished(3000) |
62 |
64 |
63 def start(self, fn, versions=None, diffMode="work2repo", stashName=""): |
65 def start(self, fn, versions=None, diffMode="work2repo", stashName=""): |
156 Private slot connected to the finished signal. |
158 Private slot connected to the finished signal. |
157 |
159 |
158 @param exitCode exit code of the process (integer) |
160 @param exitCode exit code of the process (integer) |
159 @param exitStatus exit status of the process (QProcess.ExitStatus) |
161 @param exitStatus exit status of the process (QProcess.ExitStatus) |
160 """ |
162 """ |
161 if self.process.state() == QProcess.NotRunning and \ |
163 if ( |
162 self.process2.state() == QProcess.NotRunning: |
164 self.process.state() == QProcess.NotRunning and |
|
165 self.process2.state() == QProcess.NotRunning |
|
166 ): |
163 self.finished.emit() |
167 self.finished.emit() |
164 |
168 |
165 def getResult(self): |
169 def getResult(self): |
166 """ |
170 """ |
167 Public method to return the result data. |
171 Public method to return the result data. |