[OpenLayers-Users] Legend not updating on changelayer and moveend
Jason Hochschild
sk1 at sk1consulting.com
Mon Sep 26 16:21:25 EDT 2011
When turning layers on/off and when panning my legend does not update. Only
zoom will update the legend. I have registered:
// ** REGISTER MAP EVENT TO UPDATE LEGEND AFTER LAYER CHANGE ** //
map.events.register('changelayer', map, function() {
legLyrStore.data.items[0].set("legendURL", "http:// ~getLegendGraphic ~");
});
.....
and:
// ** REGISTER MAP EVENT TO UPDATE LEGEND AFTER ZOOM OR PAN ** //
map.events.register('moveend', map, function() {
legLyrStore.data.items[0].set("legendURL", "http:// ~getLegendGraphic ~");
});
Live at: http://floodatlas.org/wcmp/DEV/
Any suggestions to get the moveend to recognize panning and tips to get
changelayer to work?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20110926/ee0c9c9b/attachment.html
More information about the Users
mailing list