Change abort button into close button after slicing with project planner. Fixes #69
This commit is contained in:
parent
8f83a2420f
commit
c35be9e4b5
1 changed files with 7 additions and 1 deletions
|
|
@ -650,7 +650,11 @@ class ProjectSliceProgressWindow(wx.Frame):
|
|||
threading.Thread(target=self.OnRun).start()
|
||||
|
||||
def OnAbort(self, e):
|
||||
self.abort = True
|
||||
if self.abort:
|
||||
self.Close()
|
||||
else:
|
||||
self.abort = True
|
||||
self.abortButton.SetLabel('Close')
|
||||
|
||||
def SetProgress(self, stepName, layer, maxLayer):
|
||||
if self.prevStep != stepName:
|
||||
|
|
@ -720,6 +724,8 @@ class ProjectSliceProgressWindow(wx.Frame):
|
|||
resultFile.write(';TYPE:CUSTOM\n')
|
||||
resultFile.write(profile.getAlterationFileContents('end.gcode'))
|
||||
resultFile.close()
|
||||
self.abort = True
|
||||
wx.CallAfter(self.abortButton.SetLabel, 'Close')
|
||||
|
||||
def main():
|
||||
app = wx.App(False)
|
||||
|
|
|
|||
Loading…
Reference in a new issue