Skip to content

Commit

Permalink
Do not attempt to ask for exit confirmation on the console when askin…
Browse files Browse the repository at this point in the history
…g for exit confirmation in GUI
  • Loading branch information
kliment committed Mar 29, 2018
1 parent 6bf59b6 commit b48fe7b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion printrun/pronsole.py
Original file line number Diff line number Diff line change
Expand Up @@ -392,7 +392,7 @@ def do_exit(self, l):
self.log("Setting bed temp to 0")
self.p.send_now("M140 S0.0")
self.log("Disconnecting from printer...")
if self.p.printing:
if self.p.printing and l is not "force":
self.log(_("Are you sure you want to exit while printing?\n\
(this will terminate the print)."))
if not self.confirm():
Expand Down
2 changes: 1 addition & 1 deletion printrun/pronterface.py
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ def on_exit(self, event):

def closewin(self, e):
e.StopPropagation()
self.do_exit("")
self.do_exit("force")

def kill(self, e=None):
if(len(self.commandbox.history)):
Expand Down

0 comments on commit b48fe7b

Please sign in to comment.