Add template based SelectionSingleton::countObjectsOfType

Also convert code to use this new method
This commit is contained in:
Benjamin Nauck
2025-01-10 19:09:50 +01:00
parent 7a5a3d1ffc
commit 08c9a191e2
22 changed files with 148 additions and 165 deletions

View File

@@ -1698,7 +1698,7 @@ bool StdCmdAlignment::isActive()
{
if (ManualAlignment::hasInstance())
return false;
return Gui::Selection().countObjectsOfType(App::GeoFeature::getClassTypeId()) == 2;
return Gui::Selection().countObjectsOfType<App::GeoFeature>() == 2;
}
//===========================================================================