FEM: mesh region, on edit hide all meshes and shapes, show the part to mesh
This commit is contained in:
parent
6822d09208
commit
862937080e
|
@ -59,6 +59,15 @@ class _ViewProviderFemMeshRegion:
|
|||
return
|
||||
|
||||
def setEdit(self, vobj, mode=0):
|
||||
# hide all meshes and shapes, show part to mesh
|
||||
for o in FreeCAD.ActiveDocument.Objects:
|
||||
if o.isDerivedFrom("Fem::FemMeshObject") or hasattr(o, "Shape"):
|
||||
o.ViewObject.hide()
|
||||
if len(self.Object.InList) == 1:
|
||||
self.Object.InList[0].Part.ViewObject.show()
|
||||
else:
|
||||
FreeCAD.Console.PrintError(self.Object.Name + ' seam to belong to more than one mesh object. This is not supported.\n')
|
||||
# show task panel
|
||||
import _TaskPanelFemMeshRegion
|
||||
taskd = _TaskPanelFemMeshRegion._TaskPanelFemMeshRegion(self.Object)
|
||||
taskd.obj = vobj.Object
|
||||
|
|
Loading…
Reference in New Issue
Block a user