Review cleanups
This commit is contained in:
committed by
Chris Hennes
parent
a674729dd3
commit
54920e6611
@@ -484,10 +484,11 @@ static std::vector<std::pair<long, Data::MappedName>> getElementSource(App::Docu
|
||||
}
|
||||
}
|
||||
if (owner->isDerivedFrom(App::GeoFeature::getClassTypeId())) {
|
||||
auto o =
|
||||
static_cast<App::GeoFeature*>(owner)->getElementOwner(ret.back().second);
|
||||
if (o)
|
||||
doc = o->getDocument();
|
||||
auto ownerGeoFeature =
|
||||
static_cast<App::GeoFeature*>(owner)->getElementOwner(ret.back().second);
|
||||
if (ownerGeoFeature) {
|
||||
doc = ownerGeoFeature->getDocument();
|
||||
}
|
||||
}
|
||||
obj = doc->getObjectByID(tag < 0 ? -tag : tag);
|
||||
if (type) {
|
||||
@@ -585,11 +586,12 @@ std::list<Data::HistoryItem> Feature::getElementHistory(App::DocumentObject* fea
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(feature->isDerivedFrom(App::GeoFeature::getClassTypeId())) {
|
||||
auto owner =
|
||||
static_cast<App::GeoFeature*>(feature)->getElementOwner(element);
|
||||
if(owner)
|
||||
doc = owner->getDocument();
|
||||
if (feature->isDerivedFrom(App::GeoFeature::getClassTypeId())) {
|
||||
auto ownerGeoFeature =
|
||||
static_cast<App::GeoFeature*>(feature)->getElementOwner(element);
|
||||
if (ownerGeoFeature) {
|
||||
doc = ownerGeoFeature->getDocument();
|
||||
}
|
||||
}
|
||||
obj = doc->getObjectByID(std::abs(tag));
|
||||
}
|
||||
|
||||
@@ -189,9 +189,6 @@ bool Body::isSolidFeature(const App::DocumentObject *obj)
|
||||
return false;
|
||||
}
|
||||
|
||||
// if (obj == BaseFeature.getValue())
|
||||
// return true;
|
||||
|
||||
if (obj->isDerivedFrom<PartDesign::Feature>()) {
|
||||
if (PartDesign::Feature::isDatum(obj)) {
|
||||
// Datum objects are not solid
|
||||
|
||||
@@ -672,8 +672,11 @@ public:
|
||||
bool& yinv,
|
||||
eReasonList* rsn = nullptr) const;
|
||||
|
||||
DocumentObject *getSubObject(const char *subname, PyObject **pyObj=0,
|
||||
Base::Matrix4D *mat=0, bool transform=true, int depth=0) const override;
|
||||
DocumentObject* getSubObject(const char* subname,
|
||||
PyObject** pyObj = 0,
|
||||
Base::Matrix4D* mat = 0,
|
||||
bool transform = true,
|
||||
int depth = 0) const override;
|
||||
|
||||
Part::TopoShape getEdge(const Part::Geometry* geo, const char* name) const;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user