Przeglądaj źródła

- fixed bug in Gerber Editor -> selection area handler where if some of the selected shapes did not had the 'solid' geometry will silently abort selection of further shapes

Marius Stanciu 6 lat temu
rodzic
commit
351da24ded
2 zmienionych plików z 5 dodań i 5 usunięć
  1. 2 1
      README.md
  2. 3 4
      flatcamEditors/FlatCAMGrbEditor.py

+ 2 - 1
README.md

@@ -20,7 +20,8 @@ CAD program, and create G-Code for Isolation routing.
 - FlatCAM can be run in HEADLESS mode now. This mode can be selected by using the --headless=1 command line argument or by changing the line headless=False to True in config/configuration.txt file. In this mod the Sys Tray Icon menu will hold only the Run Scrip menu entry and Exit entry.
 - added a new TclCommand named quit_flatcam which will ... quit FlatCAM from Tcl Shell or from a script
 - fixed the command line argument --shellvar to work when there are spaces in the argument value
-- fixed bug in Gerber editor that did not allow to display all shapes after it encouterd one shape without 'solid' geometry
+- fixed bug in Gerber editor that did not allow to display all shapes after it encountered one shape without 'solid' geometry
+- fixed bug in Gerber Editor -> selection area handler where if some of the selected shapes did not had the 'solid' geometry will silently abort selection of further shapes
 
 18.09.2019
 

+ 3 - 4
flatcamEditors/FlatCAMGrbEditor.py

@@ -4286,8 +4286,8 @@ class FlatCAMGrbEditor(QtCore.QObject):
 
         self.app.delete_selection_shape()
         for storage in self.storage_dict:
-            try:
-                for obj in self.storage_dict[storage]['geometry']:
+            for obj in self.storage_dict[storage]['geometry']:
+                if 'solid' in obj.geo:
                     geometric_data = obj.geo['solid']
                     if (sel_type is True and poly_selection.contains(geometric_data)) or \
                             (sel_type is False and poly_selection.intersects(geometric_data)):
@@ -4301,8 +4301,7 @@ class FlatCAMGrbEditor(QtCore.QObject):
                         else:
                             self.selected.append(obj)
                             sel_aperture.add(storage)
-            except KeyError:
-                pass
+
         try:
             self.apertures_table.cellPressed.disconnect()
         except Exception as e: