From 9dce167073d90460478efb0d38056e4fcb116e6e Mon Sep 17 00:00:00 2001 From: Markus Lampert Date: Sat, 6 Feb 2021 16:45:26 -0800 Subject: [PATCH] Set operation Visibility to False, and turn it back on while editing. --- src/Mod/Path/PathScripts/PathOpGui.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Mod/Path/PathScripts/PathOpGui.py b/src/Mod/Path/PathScripts/PathOpGui.py index 0aa304a5fc..93ef43f2f4 100644 --- a/src/Mod/Path/PathScripts/PathOpGui.py +++ b/src/Mod/Path/PathScripts/PathOpGui.py @@ -1094,6 +1094,8 @@ class TaskPanel(object): self.selectionFactory = selectionFactory self.obj = obj self.isdirty = deleteOnReject + self.visibility = obj.ViewObject.Visibility + obj.ViewObject.Visibility = True def isDirty(self): '''isDirty() ... returns true if the model is not in sync with the UI anymore.''' @@ -1137,6 +1139,7 @@ class TaskPanel(object): PathSelection.clear() FreeCADGui.Selection.removeObserver(self) self.obj.ViewObject.Proxy.clearTaskPanel() + self.obj.ViewObject.Visibility = self.visibility def cleanup(self, resetEdit): '''cleanup() ... implements common cleanup tasks.''' @@ -1277,6 +1280,7 @@ def Create(res): obj = res.objFactory(res.name) if obj.Proxy: obj.ViewObject.Proxy = ViewProvider(obj.ViewObject, res) + obj.ViewObject.Visibility = False FreeCAD.ActiveDocument.commitTransaction() obj.ViewObject.Document.setEdit(obj.ViewObject, 0)