ProcessGCodeJob.py 466 B

123456789101112131415
  1. # Copyright (c) 2015 Ultimaker B.V.
  2. # Cura is released under the terms of the LGPLv3 or higher.
  3. from UM.Job import Job
  4. from UM.Application import Application
  5. class ProcessGCodeLayerJob(Job):
  6. def __init__(self, message):
  7. super().__init__()
  8. self._scene = Application.getInstance().getController().getScene()
  9. self._message = message
  10. def run(self):
  11. self._scene.gcode_list.append(self._message.data.decode("utf-8", "replace"))