From 4257ed0faaaef84345442840e2c5ef2daae0ad73 Mon Sep 17 00:00:00 2001 From: Markus Lampert Date: Tue, 25 Dec 2018 19:42:12 -0800 Subject: [PATCH] Restore pocket selection behaviour --- src/Mod/Path/PathScripts/PathSelection.py | 30 +---------------------- 1 file changed, 1 insertion(+), 29 deletions(-) diff --git a/src/Mod/Path/PathScripts/PathSelection.py b/src/Mod/Path/PathScripts/PathSelection.py index 092a3719f6..6688d9ad96 100644 --- a/src/Mod/Path/PathScripts/PathSelection.py +++ b/src/Mod/Path/PathScripts/PathSelection.py @@ -168,30 +168,6 @@ class ADAPTIVEGate: return adaptive -class POCKETSHAPEGate: - def allow(self, doc, obj, sub): - - try: - obj = obj.Shape - except: - return False - - if obj.ShapeType == 'Edge': - return True - - elif obj.ShapeType == 'Face': - return True - - elif obj.ShapeType == 'Solid': - if sub and (sub[0:4] == 'Face' or sub[0:4] == 'Edge'): - return True - - elif obj.ShapeType == 'Compound': - if sub and (sub[0:4] == 'Face' or sub[0:4] == 'Edge'): - return True - - return False - class CONTOURGate: def allow(self, doc, obj, sub): pass @@ -228,10 +204,6 @@ def adaptiveselect(): FreeCADGui.Selection.addSelectionGate(ADAPTIVEGate()) FreeCAD.Console.PrintWarning("Adaptive Select Mode\n") -def pocketshapeselect(): - FreeCADGui.Selection.addSelectionGate(POCKETSHAPEGate()) - FreeCAD.Console.PrintWarning("Pocketing Select Mode (shape)\n") - def surfaceselect(): FreeCADGui.Selection.addSelectionGate(MESHGate()) FreeCAD.Console.PrintWarning("Surfacing Select Mode\n") @@ -246,7 +218,7 @@ def select(op): opsel['MillFace'] = pocketselect opsel['Pocket'] = pocketselect opsel['Pocket 3D'] = pocketselect - opsel['Pocket Shape'] = pocketshapeselect + opsel['Pocket Shape'] = pocketselect opsel['Profile Edges'] = eselect opsel['Profile Faces'] = profileselect opsel['Surface'] = surfaceselect