mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-19 12:47:49 -06:00
Recalculate disallowed borders when adding or removing objects
Because the new object may use an extruder that wasn't used so far, and if you remove an object it may remove the need for a certain extruder. Contributes to issue CURA-2625.
This commit is contained in:
parent
6bb82eeefe
commit
9be02fb31f
1 changed files with 1 additions and 3 deletions
|
@ -104,9 +104,7 @@ class BuildVolume(SceneNode):
|
||||||
root = Application.getInstance().getController().getScene().getRoot()
|
root = Application.getInstance().getController().getScene().getRoot()
|
||||||
new_number_of_objects = len([node for node in BreadthFirstIterator(root) if node.getMeshData() and type(node) is SceneNode])
|
new_number_of_objects = len([node for node in BreadthFirstIterator(root) if node.getMeshData() and type(node) is SceneNode])
|
||||||
if new_number_of_objects != self._number_of_objects:
|
if new_number_of_objects != self._number_of_objects:
|
||||||
recalculate = False
|
recalculate = new_number_of_objects != self._number_of_objects
|
||||||
if self._global_container_stack.getProperty("print_sequence", "value") == "one_at_a_time":
|
|
||||||
recalculate = (new_number_of_objects < 2 and self._number_of_objects > 1) or (new_number_of_objects > 1 and self._number_of_objects < 2)
|
|
||||||
self._number_of_objects = new_number_of_objects
|
self._number_of_objects = new_number_of_objects
|
||||||
if recalculate:
|
if recalculate:
|
||||||
self._onSettingPropertyChanged("print_sequence", "value") # Create fake event, so right settings are triggered.
|
self._onSettingPropertyChanged("print_sequence", "value") # Create fake event, so right settings are triggered.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue