Mercurial > lada > lada-client
comparison app/view/panel/Map.js @ 1373:94d35d5a7913
update other panels if ortegrid changes
author | Maximilian Krambach <mkrambach@intevation.de> |
---|---|
date | Thu, 09 Feb 2017 11:54:22 +0100 |
parents | 5c2d6812d85a |
children | 9cac9eb1365f |
comparison
equal
deleted
inserted
replaced
1372:f2db1da82297 | 1373:94d35d5a7913 |
---|---|
203 this.map.addControl(this.selectControl); | 203 this.map.addControl(this.selectControl); |
204 this.selectControl.activate(); | 204 this.selectControl.activate(); |
205 } | 205 } |
206 this.featureLayer.removeAllFeatures(); | 206 this.featureLayer.removeAllFeatures(); |
207 this.featureLayer.addFeatures(locationFeatures); | 207 this.featureLayer.addFeatures(locationFeatures); |
208 if (this.selectedFeatureLayer && this.selectedFeatureLayer.features){ | |
209 var oldSelection = this.selectedFeatureLayer.features[0].data.id; | |
210 var feature = this.featureLayer.getFeaturesByAttribute('id', oldSelection)[0]; | |
211 this.selectControl.unselectAll(); | |
212 this.selectedFeatureLayer.removeAllFeatures(); | |
213 this.selectedFeatureLayer.addFeatures(feature.clone()); | |
214 this.featureLayer.removeFeatures([feature]); | |
215 this.selectedFeatureLayer.refresh({force: true}); | |
216 this.featureLayer.refresh({force: true}); | |
217 } | |
208 this.map.addLayer(this.featureLayer); | 218 this.map.addLayer(this.featureLayer); |
209 }, | 219 }, |
210 | 220 |
211 /** | 221 /** |
212 * @private | 222 * @private |