PartDesign: decouple refine and other geometric computation (#17008)

This commit is contained in:
Florian Foinant-Willig
2024-12-02 17:57:30 +01:00
committed by GitHub
parent e5c2c81685
commit 70184ba59d
14 changed files with 141 additions and 5 deletions

View File

@@ -60,6 +60,29 @@ short FeatureAddSub::mustExecute() const
return PartDesign::Feature::mustExecute();
}
bool FeatureAddSub::onlyHasToRefine() const
{
if( ! Refine.isTouched()){
return false;
}
if (rawShape.isNull()){
return false;
}
std::vector<App::Property*> propList;
getPropertyList(propList);
for (auto prop : propList){
if (prop != &Refine
/*&& prop != &SuppressedShape*/
&& prop->isTouched()){
return false;
}
}
return true;
}
TopoShape FeatureAddSub::refineShapeIfActive(const TopoShape& oldShape, const RefineErrorPolicy onError) const
{
if (this->Refine.getValue()) {