mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-13 03:09:04 +08:00
Use getMultiBuildPlateModel()
This commit is contained in:
parent
025239c26e
commit
4a202d6728
@ -1046,7 +1046,7 @@ class CuraApplication(QtApplication):
|
|||||||
count = 0
|
count = 0
|
||||||
scene_bounding_box = None
|
scene_bounding_box = None
|
||||||
is_block_slicing_node = False
|
is_block_slicing_node = False
|
||||||
active_build_plate = self._multi_build_plate_model.activeBuildPlate
|
active_build_plate = self.getMultiBuildPlateModel().activeBuildPlate
|
||||||
for node in DepthFirstIterator(self.getController().getScene().getRoot()):
|
for node in DepthFirstIterator(self.getController().getScene().getRoot()):
|
||||||
if (
|
if (
|
||||||
not issubclass(type(node), CuraSceneNode) or
|
not issubclass(type(node), CuraSceneNode) or
|
||||||
@ -1295,7 +1295,7 @@ class CuraApplication(QtApplication):
|
|||||||
@pyqtSlot()
|
@pyqtSlot()
|
||||||
def arrangeAll(self):
|
def arrangeAll(self):
|
||||||
nodes = []
|
nodes = []
|
||||||
active_build_plate = self._multi_build_plate_model.activeBuildPlate
|
active_build_plate = self.getMultiBuildPlateModel().activeBuildPlate
|
||||||
for node in DepthFirstIterator(self.getController().getScene().getRoot()):
|
for node in DepthFirstIterator(self.getController().getScene().getRoot()):
|
||||||
if not isinstance(node, SceneNode):
|
if not isinstance(node, SceneNode):
|
||||||
continue
|
continue
|
||||||
@ -1444,7 +1444,7 @@ class CuraApplication(QtApplication):
|
|||||||
group_decorator = GroupDecorator()
|
group_decorator = GroupDecorator()
|
||||||
group_node.addDecorator(group_decorator)
|
group_node.addDecorator(group_decorator)
|
||||||
group_node.addDecorator(ConvexHullDecorator())
|
group_node.addDecorator(ConvexHullDecorator())
|
||||||
group_node.addDecorator(BuildPlateDecorator(self._multi_build_plate_model.activeBuildPlate))
|
group_node.addDecorator(BuildPlateDecorator(self.getMultiBuildPlateModel().activeBuildPlate))
|
||||||
group_node.setParent(self.getController().getScene().getRoot())
|
group_node.setParent(self.getController().getScene().getRoot())
|
||||||
group_node.setSelectable(True)
|
group_node.setSelectable(True)
|
||||||
center = Selection.getSelectionCenter()
|
center = Selection.getSelectionCenter()
|
||||||
@ -1589,7 +1589,7 @@ class CuraApplication(QtApplication):
|
|||||||
arrange_objects_on_load = (
|
arrange_objects_on_load = (
|
||||||
not Preferences.getInstance().getValue("cura/use_multi_build_plate") or
|
not Preferences.getInstance().getValue("cura/use_multi_build_plate") or
|
||||||
not Preferences.getInstance().getValue("cura/not_arrange_objects_on_load"))
|
not Preferences.getInstance().getValue("cura/not_arrange_objects_on_load"))
|
||||||
target_build_plate = self._multi_build_plate_model.activeBuildPlate if arrange_objects_on_load else -1
|
target_build_plate = self.getMultiBuildPlateModel().activeBuildPlate if arrange_objects_on_load else -1
|
||||||
|
|
||||||
root = self.getController().getScene().getRoot()
|
root = self.getController().getScene().getRoot()
|
||||||
fixed_nodes = []
|
fixed_nodes = []
|
||||||
|
Loading…
x
Reference in New Issue
Block a user