FEM: Python object base classes, some tweaks
This commit is contained in:
@@ -97,8 +97,7 @@ class ViewProxy(object):
|
||||
FreeCAD.Console.PrintError(message + "\n")
|
||||
return True
|
||||
|
||||
def __getstate__(self):
|
||||
return None
|
||||
|
||||
# a few objects had this method in their class before the move to this base class
|
||||
# these objects will give a setAttr failed error on document loading without this method
|
||||
def __setstate__(self, state):
|
||||
return None
|
||||
|
||||
@@ -37,4 +37,10 @@ class Proxy(object):
|
||||
self.Object = obj # keep a ref to the DocObj for nonGui usage
|
||||
obj.Proxy = self # link between App::DocumentObject to this object
|
||||
|
||||
# a few objects had this method in their class before the move to this base class
|
||||
# these objects will give a setAttr failed error on document loading without this method
|
||||
def __setstate__(self, state):
|
||||
if state:
|
||||
self.Type = state
|
||||
|
||||
## @}
|
||||
|
||||
Reference in New Issue
Block a user