Skip to content

Commit

Permalink
Merge pull request #693 from geographika/selection-selectedFeatures
Browse files Browse the repository at this point in the history
Ensure correct selectedFeatures is used for GeoExt.selection.FeatureModelMixin
  • Loading branch information
geographika committed Jun 17, 2021
2 parents 73d7d88 + bbf304d commit 871da3b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions classic/selection/FeatureModelMixin.js
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,6 @@ Ext.define('GeoExt.selection.FeatureModelMixin', {
bindFeatureModel: function() {
var me = this;

me.selectedFeatures = new ol.Collection();

// detect a layer from the store if not passed in
if (!me.layer || !(me.layer instanceof ol.layer.Vector)) {
var store = me.getStore();
Expand All @@ -157,6 +155,8 @@ Ext.define('GeoExt.selection.FeatureModelMixin', {
if (!this.bound_) {
var me = this;

me.selectedFeatures = new ol.Collection();

// change style of selected feature
me.selectedFeatures.on('add', me.onSelectFeatAdd);

Expand Down

0 comments on commit 871da3b

Please sign in to comment.