PartDesign: Primitives are attachable directly
With the recently introduced AttachExtension the PartDesign primitives can be attachable by themself and don't need anymore the helping coordinate system datum. This simplyfies the code and the TreeView largely
This commit is contained in:
@@ -355,13 +355,6 @@ bool isFeatureMovable(App::DocumentObject* const feat)
|
||||
return false;
|
||||
}
|
||||
|
||||
if (feat->getTypeId().isDerivedFrom(PartDesign::FeaturePrimitive::getClassTypeId())) {
|
||||
auto prim = static_cast<PartDesign::FeaturePrimitive*>(feat);
|
||||
|
||||
if (!isFeatureMovable(prim->CoordinateSystem.getValue()))
|
||||
return false;
|
||||
}
|
||||
|
||||
if (feat->getTypeId().isDerivedFrom(PartDesign::ProfileBased::getClassTypeId())) {
|
||||
auto prim = static_cast<PartDesign::ProfileBased*>(feat);
|
||||
auto sk = prim->getVerifiedSketch(true);
|
||||
@@ -410,13 +403,6 @@ std::vector<App::DocumentObject*> collectMovableDependencies(std::vector<App::Do
|
||||
|
||||
for (auto const &feat : features)
|
||||
{
|
||||
// Get coordinate system object
|
||||
if (feat->getTypeId().isDerivedFrom(PartDesign::FeaturePrimitive::getClassTypeId())) {
|
||||
auto prim = static_cast<PartDesign::FeaturePrimitive*>(feat);
|
||||
App::DocumentObject* cs = prim->CoordinateSystem.getValue();
|
||||
if (cs && cs->getTypeId() == PartDesign::CoordinateSystem::getClassTypeId())
|
||||
unique_objs.insert(cs);
|
||||
}
|
||||
|
||||
// Get sketches and datums from profile based features
|
||||
if (feat->getTypeId().isDerivedFrom(PartDesign::ProfileBased::getClassTypeId())) {
|
||||
|
||||
Reference in New Issue
Block a user