FEM: use python base constraint class, result mechanical

This commit is contained in:
Bernd Hahnebach
2020-03-03 21:04:49 +01:00
parent 95a411d95a
commit 36118fb59e
2 changed files with 16 additions and 55 deletions

View File

@@ -27,14 +27,17 @@ __url__ = "http://www.freecadweb.org"
# \ingroup FEM
# \brief FreeCAD DocumentObject class to hold mechanical results in FEM workbench
from . import FemConstraint
class _FemResultMechanical():
class _FemResultMechanical(FemConstraint.Proxy):
"""The Fem::_FemResultMechanical's Proxy python type, add result specific properties
"""
Type = "Fem::FemResultMechanical"
def __init__(self, obj):
self.Type = "Fem::FemResultMechanical"
self.Object = obj # keep a ref to the DocObj for nonGui usage
obj.Proxy = self # link between App::DocumentObject to this object
super(_FemResultMechanical, self).__init__(obj)
obj.addProperty(
"App::PropertyString",