From 86d9191023e28d67307fdec4e09ad8cb69335c6f Mon Sep 17 00:00:00 2001 From: Markus Lampert Date: Sun, 1 Oct 2017 13:11:15 -0700 Subject: [PATCH] Setting obj.removalshape to the first one if there are any for convenience. --- src/Mod/Path/PathScripts/PathPocketShape.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Mod/Path/PathScripts/PathPocketShape.py b/src/Mod/Path/PathScripts/PathPocketShape.py index 155fecd9d7..1c9a90b0b2 100644 --- a/src/Mod/Path/PathScripts/PathPocketShape.py +++ b/src/Mod/Path/PathScripts/PathPocketShape.py @@ -126,12 +126,13 @@ class ObjectPocket(PathPocketBase.ObjectPocket): self.outline.translate(FreeCAD.Vector(0, 0, stockBB.ZMin - 1)) self.body = self.outline.extrude(FreeCAD.Vector(0, 0, stockBB.ZLength + 2)) - obj.removalshape = self.stock.Shape.cut(self.body) - self.removalshapes = [(obj.removalshape, False)] + self.removalshapes = [(self.stock.Shape.cut(self.body), False)] for (shape,hole) in self.removalshapes: shape.tessellate(0.1) + if self.removalshapes: + obj.removalshape = self.removalshapes[0][0] return self.removalshapes def areaOpSetDefaultValues(self, obj):