diff --git a/ViaStitching/FillArea.py b/ViaStitching/FillArea.py index ebd79ca..25bdb79 100644 --- a/ViaStitching/FillArea.py +++ b/ViaStitching/FillArea.py @@ -362,11 +362,6 @@ STEP = '-' print("Group {} Found !".format(VIA_GROUP_NAME)) self.pcb_group = i - if self.pcb_group is None: - self.pcb_group = PCB_GROUP(None) - self.pcb_group.SetName(VIA_GROUP_NAME) - self.pcb.Add(self.pcb_group) - """ Launch the process """ @@ -377,6 +372,11 @@ STEP = '-' "To delete vias:\n - select one of the generated via to select the group of vias named {}\n - hit delete key\n - That's all !".format(VIA_GROUP_NAME), "Information") return # no need to run the rest of logic + if self.pcb_group is None: + self.pcb_group = PCB_GROUP(None) + self.pcb_group.SetName(VIA_GROUP_NAME) + self.pcb.Add(self.pcb_group) + if self.debug: print("%s: Line %u" % (time.time(), currentframe().f_lineno)) target_tracks = self.pcb.GetTracks() diff --git a/ViaStitching/FillAreaDialog.py b/ViaStitching/FillAreaDialog.py index a8bcade..64ca4b8 100644 --- a/ViaStitching/FillAreaDialog.py +++ b/ViaStitching/FillAreaDialog.py @@ -137,7 +137,7 @@ class FillAreaDialog (wx.Dialog): self.Centre(wx.BOTH) # Connect Events - #self.m_button3_delete.Bind( wx.EVT_BUTTON, self.onDeleteClick ) + self.m_button3_delete.Bind(wx.EVT_BUTTON, self.onDeleteClick) def __del__(self): pass