mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2024-12-24 08:20:34 +05:00
#17319: EDF 20003 - suppress Meshes in TUI
This commit is contained in:
parent
c76543a1ab
commit
66f913b253
@ -475,6 +475,24 @@ class smeshBuilder( SMESH._objref_SMESH_Gen, object ):
|
||||
obj,name = name,obj
|
||||
return Mesh(self, self.geompyD, obj, name)
|
||||
|
||||
def RemoveMesh( self, mesh ):
|
||||
"""
|
||||
Delete a mesh
|
||||
"""
|
||||
if isinstance( mesh, Mesh ):
|
||||
mesh = mesh.GetMesh()
|
||||
pass
|
||||
if not isinstance( mesh, SMESH._objref_SMESH_Mesh ):
|
||||
raise TypeError("%s is not a mesh" % mesh )
|
||||
so = salome.ObjectToSObject( mesh )
|
||||
if so:
|
||||
sb = salome.myStudy.NewBuilder()
|
||||
sb.RemoveObjectWithChildren( so )
|
||||
else:
|
||||
mesh.UnRegister()
|
||||
pass
|
||||
return
|
||||
|
||||
def EnumToLong(self,theItem):
|
||||
"""
|
||||
Return a long value from enumeration
|
||||
|
Loading…
Reference in New Issue
Block a user