- if (aRefFeatures.empty())
- continue;
- // 3. Find any placed features in all reference features
- std::set<FeaturePtr> aIntersectionFeatures;
- std::set_intersection(aRefFeatures.begin(), aRefFeatures.end(),
- aPlacedFeatures.begin(), aPlacedFeatures.end(),
- std::inserter(aIntersectionFeatures, aIntersectionFeatures.begin()));
- // 4. Return false if any reference feature is placed before curent feature
- if (!aIntersectionFeatures.empty())
- return false;
+ if (aRefFeatures.empty())
+ continue;
+ else {
+ // 3. Find any placed features in all reference features
+ std::set<FeaturePtr> aIntersectionFeatures;
+ std::set_intersection(aRefFeatures.begin(), aRefFeatures.end(),
+ aPlacedFeatures.begin(), aPlacedFeatures.end(),
+ std::inserter(aIntersectionFeatures, aIntersectionFeatures.begin()));
+ // 4. Return false if any reference feature is placed before curent feature
+ if (!aIntersectionFeatures.empty())
+ aCanMove = false;
+ }
+ }