Specialized viewproviders for datum features, create points from intersection of edges and faces

This commit is contained in:
jrheinlaender
2016-04-12 18:11:49 +02:00
committed by Stefan Tröger
parent 8682b5f490
commit 1c1531278c
10 changed files with 457 additions and 174 deletions
+14 -2
View File
@@ -180,8 +180,20 @@ const bool Body::isAfterTip(const App::DocumentObject *f) {
const bool Body::isSolidFeature(const App::DocumentObject* f)
{
return (f->getTypeId().isDerivedFrom(PartDesign::Feature::getClassTypeId()) &&
!f->getTypeId().isDerivedFrom(PartDesign::Datum::getClassTypeId()));
if (f == NULL)
return false;
return (f->getTypeId().isDerivedFrom(PartDesign::Feature::getClassTypeId()));
}
const bool Body::isAllowed(const App::DocumentObject* f)
{
if (f == NULL)
return false;
return (f->getTypeId().isDerivedFrom(PartDesign::Feature::getClassTypeId()) ||
f->getTypeId().isDerivedFrom(PartDesign::Datum::getClassTypeId()) ||
f->getTypeId().isDerivedFrom(Part::Part2DObject::getClassTypeId()));
}
Body* Body::findBodyOf(const App::DocumentObject* f)