FEM: use python base constraint class, mesh result mesh

This commit is contained in:
Bernd Hahnebach
2020-03-03 21:04:51 +01:00
parent 72bec9d410
commit 6791b0bb1c
2 changed files with 9 additions and 33 deletions

View File

@@ -27,22 +27,14 @@ __url__ = "http://www.freecadweb.org"
# \ingroup FEM
# \brief FreeCAD FEM _FemMeshResult
from . import FemConstraint
class _FemMeshResult():
class _FemMeshResult(FemConstraint.Proxy):
"""The Fem::FemMeshObject's Proxy python type, add Result specific object type
"""
Type = "Fem::FemMeshResult"
def __init__(self, obj):
self.Type = "Fem::FemMeshResult"
self.Object = obj # keep a ref to the DocObj for nonGui usage
obj.Proxy = self # link between App::DocumentObject to this object
def execute(self, obj):
return
def __getstate__(self):
return self.Type
def __setstate__(self, state):
if state:
self.Type = state
super(_FemMeshResult, self).__init__(obj)