CURA-5562 Don't trigger the stop slicing if some nodes without build

plate associated with it changes in the scene, such as the NozzleNode in
the SimulationView.
This commit is contained in:
Diego Prado Gesto 2018-07-12 14:34:42 +02:00
parent 461b191648
commit e88362930d

View file

@ -457,6 +457,7 @@ class CuraEngineBackend(QObject, Backend):
# Only count sliceable objects # Only count sliceable objects
if node.callDecoration("isSliceable"): if node.callDecoration("isSliceable"):
build_plate_number = node.callDecoration("getBuildPlateNumber") build_plate_number = node.callDecoration("getBuildPlateNumber")
if build_plate_number is not None:
num_objects[build_plate_number] += 1 num_objects[build_plate_number] += 1
return num_objects return num_objects
@ -490,6 +491,8 @@ class CuraEngineBackend(QObject, Backend):
if mesh_data and mesh_data.getVertices() is None: if mesh_data and mesh_data.getVertices() is None:
return return
# There are some SceneNodes that do not have any build plate associated, then do not add to the list.
if source_build_plate_number is not None:
build_plate_changed.add(source_build_plate_number) build_plate_changed.add(source_build_plate_number)
if not build_plate_changed: if not build_plate_changed: