Select to view content in your preferred language

Event for Layer visibility changed?

2009
3
04-08-2011 05:34 AM
FalkoWieland
Emerging Contributor
In my Widget it is necessary to handle changed visibility of Layers. Is there a event witch raises when the visibility of a Layer changed due to MapSwitchWidget or LayerListWidget and how to catch it?

Thanks a lot in advance

Falko
Tags (2)
0 Kudos
3 Replies
FalkoWieland
Emerging Contributor
In my widget i used
map.addEventListener(PanEvent.PAN_END,panEventListener);
to catch a pan of the map, but cannot find a event for changed visibility.
0 Kudos
DasaPaddock
Esri Regular Contributor
See com.esri.viewer.components.toc.tocClasses.TocMapLayerItem for an example where it's listening to FlexEvent.SHOW and FlexEvent.HIDE.
0 Kudos
FalkoWieland
Emerging Contributor
Thanks Dasa. That did it.
0 Kudos