diff --git a/cura/ArrangeObjectsAllBuildPlatesJob.py b/cura/ArrangeObjectsAllBuildPlatesJob.py index 7991ac39f0..f062c2b23b 100644 --- a/cura/ArrangeObjectsAllBuildPlatesJob.py +++ b/cura/ArrangeObjectsAllBuildPlatesJob.py @@ -34,8 +34,6 @@ class ArrangeArray: if a.isEmpty: self._first_empty = i self._has_empty = True - - Logger.log("d", "lala %s %s", self._first_empty, self._has_empty) return self._first_empty = None self._has_empty = False diff --git a/cura/BuildPlateModel.py b/cura/BuildPlateModel.py index c832a7c522..118a5ce271 100644 --- a/cura/BuildPlateModel.py +++ b/cura/BuildPlateModel.py @@ -40,7 +40,11 @@ class BuildPlateModel(ListModel): def maxBuildPlate(self): return self._max_build_plate - def updateMaxBuildPlate(self, source): + def updateMaxBuildPlate(self, *args): + if args: + source = args[0] + else: + source = None if not issubclass(type(source), SceneNode): return max_build_plate = self._calcMaxBuildPlate() diff --git a/cura/Scene/BuildPlateDecorator.py b/cura/Scene/BuildPlateDecorator.py index 6a288b4bcd..36b89c5e5d 100644 --- a/cura/Scene/BuildPlateDecorator.py +++ b/cura/Scene/BuildPlateDecorator.py @@ -1,6 +1,5 @@ from UM.Scene.SceneNodeDecorator import SceneNodeDecorator -from UM.Application import Application -from UM.Logger import Logger +from UM.Scene.SceneNode import SceneNode ## Make a SceneNode build plate aware CuraSceneNode objects all have this decorator. @@ -14,13 +13,14 @@ class BuildPlateDecorator(SceneNodeDecorator): # Make sure that groups are set correctly # setBuildPlateForSelection in CuraActions makes sure that no single childs are set. self._build_plate_number = nr - if self._node is not None: - self._node.transformationChanged.emit() + # if issubclass(type(self._node), SceneNode): # TODO: Crashes on ArrangeObjectsAllBuildPlatesJob + # self._node.transformationChanged.emit() #self._node.transformationChanged.emit() if self._node and self._node.callDecoration("isGroup"): for child in self._node.getChildren(): child.callDecoration("setBuildPlateNumber", nr) - child.transformationChanged.emit() + # if issubclass(type(child), SceneNode): + # child.transformationChanged.emit() def getBuildPlateNumber(self): return self._build_plate_number diff --git a/resources/qml/Actions.qml b/resources/qml/Actions.qml index 0727642d7e..93861c0963 100644 --- a/resources/qml/Actions.qml +++ b/resources/qml/Actions.qml @@ -316,7 +316,6 @@ Item { id: arrangeAllBuildPlatesAction; text: catalog.i18nc("@action:inmenu menubar:edit","Arrange All Models To All Build Plates"); - //iconName: "document-open"; onTriggered: Printer.arrangeObjectsToAllBuildPlates(); } diff --git a/resources/qml/ObjectsList.qml b/resources/qml/ObjectsList.qml index e688928570..761ff6d3f5 100644 --- a/resources/qml/ObjectsList.qml +++ b/resources/qml/ObjectsList.qml @@ -146,6 +146,7 @@ Rectangle onClicked: UM.Preferences.setValue("view/filter_current_build_plate", checked) text: catalog.i18nc("@option:check","See only current build plate"); + style: UM.Theme.styles.checkbox; anchors { @@ -192,6 +193,7 @@ Rectangle frameVisible: true height: UM.Theme.getSize("build_plate_selection_size").height width: parent.width - 2 * UM.Theme.getSize("default_margin").height + style: UM.Theme.styles.scrollview anchors { @@ -222,9 +224,8 @@ Rectangle { id: arrangeAllBuildPlatesButton; text: catalog.i18nc("@action:button","Arrange to all build plates"); - //iconSource: UM.Theme.getIcon("load") - //style: UM.Theme.styles.tool_button - height: 25 + style: UM.Theme.styles.sidebar_action_button + height: UM.Theme.getSize("objects_menu_button").height; tooltip: ''; anchors { @@ -244,7 +245,8 @@ Rectangle { id: arrangeBuildPlateButton; text: catalog.i18nc("@action:button","Arrange current build plate"); - height: 25 + style: UM.Theme.styles.sidebar_action_button + height: UM.Theme.getSize("objects_menu_button").height; tooltip: ''; anchors { diff --git a/resources/themes/cura-light/theme.json b/resources/themes/cura-light/theme.json index 714e578d97..18f2650e77 100644 --- a/resources/themes/cura-light/theme.json +++ b/resources/themes/cura-light/theme.json @@ -393,8 +393,9 @@ "jobspecs_line": [2.0, 2.0], - "objects_menu_size": [17, 40], + "objects_menu_size": [20, 40], "objects_menu_size_collapsed": [15, 15], - "build_plate_selection_size": [15, 5] + "build_plate_selection_size": [15, 5], + "objects_menu_button": [0.3, 2.7] } }