[TD]allow multiple primitives in complex selections

This commit is contained in:
wandererfan
2024-05-25 18:48:24 -04:00
committed by WandererFan
parent f41c634a23
commit 5b17a73d71
3 changed files with 23 additions and 7 deletions

View File

@@ -612,3 +612,16 @@ Base::Vector3d DrawGuiUtil::toGuiPoint(DrawView* obj, const Base::Vector3d& toCo
return result;
}
//! true if targetObj is in the selection list
bool DrawGuiUtil::findObjectInSelection(const std::vector<Gui::SelectionObject>& selection,
const App::DocumentObject& targetObject)
{
for (auto& selObj : selection) {
if (&targetObject == selObj.getObject()) {
return true;
}
}
return false;
}