update source and fire event only if features added
This commit is contained in:
@@ -147,9 +147,6 @@ class DragAndDrop extends Interaction {
|
||||
featureProjection: projection,
|
||||
});
|
||||
if (features && features.length > 0) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (this.source_) {
|
||||
this.source_.clear();
|
||||
this.source_.addFeatures(features);
|
||||
@@ -162,6 +159,9 @@ class DragAndDrop extends Interaction {
|
||||
projection
|
||||
)
|
||||
);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user