Fix wrong detection of multiple GeoFeatureGroups
This commit is contained in:
@@ -198,10 +198,11 @@ void GeoFeatureGroupExtension::extensionOnChanged(const Property* p) {
|
||||
//would return anyone of it and hence it is possible that we miss an error. We need a custom check
|
||||
auto list = obj->getInList();
|
||||
for (auto in : list) {
|
||||
if(in->hasExtension(App::GeoFeatureGroupExtension::getExtensionClassTypeId()) &&
|
||||
in != getExtendedObject()) {
|
||||
error = true;
|
||||
corrected.erase(std::remove(corrected.begin(), corrected.end(), obj), corrected.end());
|
||||
if(in->hasExtension(App::GeoFeatureGroupExtension::getExtensionClassTypeId()) && //is GeoFeatureGroup?
|
||||
in != getExtendedObject() && //is a different one?
|
||||
in->getExtensionByType<App::GeoFeatureGroupExtension>()->hasObject(obj)) { //is not a non-grouping link?
|
||||
error = true;
|
||||
corrected.erase(std::remove(corrected.begin(), corrected.end(), obj), corrected.end());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user