toolhead: Don't call _process_moves() if no moves present
Don't transition to the normal movement state if there aren't any moves actually ready to be processed. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
parent
dd529d7ad1
commit
503891cd0e
|
@ -167,10 +167,12 @@ class MoveQueue:
|
|||
return
|
||||
# Allow extruder to do its lookahead
|
||||
move_count = self.extruder_lookahead(queue, flush_count, lazy)
|
||||
self.leftover = flush_count - move_count
|
||||
if not move_count:
|
||||
return
|
||||
# Generate step times for all moves ready to be flushed
|
||||
self.toolhead._process_moves(queue[:move_count])
|
||||
# Remove processed moves from the queue
|
||||
self.leftover = flush_count - move_count
|
||||
del queue[:move_count]
|
||||
def add_move(self, move):
|
||||
self.queue.append(move)
|
||||
|
|
Loading…
Reference in New Issue