[OpenLayers-Users] Selected feature is unselected when zooming
Trond Michelsen
trondmm-openlayers at crusaders.no
Tue Apr 12 12:16:37 EDT 2011
Hi.
I've set up an onSelect handler, using
OpenLayers.Control.SelectFeature, for a wfs layer, and I want to zoom
in on the feature the user clicks on. This works pretty well, but if
openlayers needs to change zoomlevel, the feature is unselected. If
openlayers can get by with panning, the feature stays selected.
Example here:
http://wms.met.no/klimaportal/
How do I reselect the feature? Calling feature.select() after
map.zoomToExtent() has no effect. Do I need to create a zoomend
handler on the map?
--
Trond Michelsen
More information about the Users
mailing list