FEM: Backward compatibility for post pipeline and multiple fixes
This commit is contained in:
committed by
Benjamin Nauck
parent
53a7e5ab34
commit
c8a4ff0a70
@@ -44,7 +44,7 @@ bool FemPostFunctionProvider::allowObject(App::DocumentObject* obj)
|
||||
return obj->isDerivedFrom(FemPostFunction::getClassTypeId());
|
||||
}
|
||||
|
||||
void FemPostFunctionProvider::unsetupObject()
|
||||
void FemPostFunctionProvider::unsetupObject()
|
||||
{
|
||||
// remove all children!
|
||||
auto document = getExtendedObject()->getDocument();
|
||||
@@ -53,6 +53,24 @@ void FemPostFunctionProvider::unsetupObject()
|
||||
}
|
||||
}
|
||||
|
||||
void FemPostFunctionProvider::handleChangedPropertyName(Base::XMLReader& reader,
|
||||
const char* typeName,
|
||||
const char* propName)
|
||||
{
|
||||
if (strcmp(propName, "Functions") == 0
|
||||
&& Base::Type::fromName(typeName) == App::PropertyLinkList::getClassTypeId()) {
|
||||
|
||||
// add the formerly Functions values to the group
|
||||
App::PropertyLinkList functions;
|
||||
functions.setContainer(this);
|
||||
functions.Restore(reader);
|
||||
Group.setValues(functions.getValues());
|
||||
}
|
||||
else {
|
||||
App::DocumentObject::handleChangedPropertyName(reader, typeName, propName);
|
||||
}
|
||||
}
|
||||
|
||||
PROPERTY_SOURCE(Fem::FemPostFunction, App::DocumentObject)
|
||||
|
||||
FemPostFunction::FemPostFunction() = default;
|
||||
|
||||
Reference in New Issue
Block a user