Commit 07fae14c authored by kliment's avatar kliment

Merge pull request #335 from KazW/experimental

Add checking to pause/resume functions in printcore.py
parents 197f0ac1 8fb6c98d
P-face.png

8.85 KB

plater.png

2.04 KB

...@@ -222,6 +222,7 @@ class printcore(): ...@@ -222,6 +222,7 @@ class printcore():
def pause(self): def pause(self):
"""Pauses the print, saving the current position. """Pauses the print, saving the current position.
""" """
return False if !self.printing
self.paused = True self.paused = True
self.printing = False self.printing = False
self.print_thread.join() self.print_thread.join()
...@@ -230,6 +231,7 @@ class printcore(): ...@@ -230,6 +231,7 @@ class printcore():
def resume(self): def resume(self):
"""Resumes a paused print. """Resumes a paused print.
""" """
return False if !self.paused
self.paused = False self.paused = False
self.printing = True self.printing = True
self.print_thread = Thread(target = self._print) self.print_thread = Thread(target = self._print)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment