From 1fd34ab1248ada5dca9d6a5d30a7a6330173f0d6 Mon Sep 17 00:00:00 2001 From: PaddleStroke Date: Mon, 26 Feb 2024 12:10:45 +0100 Subject: [PATCH] Assembly : Typos --- src/Mod/Assembly/JointObject.py | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/src/Mod/Assembly/JointObject.py b/src/Mod/Assembly/JointObject.py index 2586f1b821..e37d5fe0aa 100644 --- a/src/Mod/Assembly/JointObject.py +++ b/src/Mod/Assembly/JointObject.py @@ -313,8 +313,6 @@ class Joint: isAssembly = assembly.Type == "Assembly" if len(current_selection) >= 1: - joint.Part1 = None - joint.Object1 = current_selection[0]["object"].Name joint.Part1 = current_selection[0]["part"] joint.Element1 = current_selection[0]["element_name"] @@ -331,8 +329,6 @@ class Joint: self.partMovedByPresolved = None if len(current_selection) >= 2: - joint.Part2 = None - joint.Object2 = current_selection[1]["object"].Name joint.Part2 = current_selection[1]["part"] joint.Element2 = current_selection[1]["element_name"] @@ -1347,7 +1343,7 @@ class TaskAssemblyCreateJoint(QtCore.QObject): # First we build the listwidget self.updateJointList() - # Then we pass the new list to the join object + # Then we pass the new list to the joint object self.joint.Proxy.setJointConnectors(self.joint, self.current_selection) def updateJointList(self): @@ -1456,15 +1452,11 @@ class TaskAssemblyCreateJoint(QtCore.QObject): part_containing_selected_object = self.getContainingPart(full_element_name, selected_object) # Find and remove the corresponding dictionary from the combined list - selection_dict_to_remove = None for selection_dict in self.current_selection: if selection_dict["part"] == part_containing_selected_object: - selection_dict_to_remove = selection_dict + self.current_selection.remove(selection_dict) break - if selection_dict_to_remove is not None: - self.current_selection.remove(selection_dict_to_remove) - self.updateJoint() def setPreselection(self, doc_name, obj_name, sub_name):