show base feature's placement on load if not part of a body

This commit is contained in:
wmayer
2017-12-20 22:01:24 +01:00
parent 60b8b0da67
commit 5b358e1bd9
2 changed files with 9 additions and 2 deletions

View File

@@ -91,7 +91,13 @@ void FeatureBase::onChanged(const App::Property* prop) {
Part::Feature::onChanged(prop);
}
void FeatureBase::onDocumentRestored()
{
// if the base is not part of a body then show its placement property again
auto body = getFeatureBody();
if (!body)
Placement.setStatus(App::Property::Hidden, false);
}
}//namespace PartDesign

View File

@@ -48,7 +48,8 @@ public:
}
virtual void onChanged(const App::Property* prop);
virtual App::DocumentObjectExecReturn* execute(void);
virtual App::DocumentObjectExecReturn* execute(void);
virtual void onDocumentRestored();
};
} //namespace PartDesign