0

I'm listening to a layer's event change:visible. However it does not get fired when the resolution changes.

I.E. my layer as a minimum resolution of 0.5964957884324376. If I zoom past it, even though my layer is no longer displayed on the map, the event is not fired and its visible state is still true.

How can I detect my layer is no longer displayed because of its min/max resolution setup ?

  • need minimum code on fiddle – Chase Choi Oct 19 '17 at 3:01
  • Some code would not help here. My question is : how can I know a layer is no longer visible on the map ? – vegemat Oct 26 '17 at 8:50
  • The event change:visible is not fired, because visibility is not changed if the layer is outside min/max resolution limits. Did anybody find a solution to this? Here is a jsfiddle with the problem: jsfiddle.net/beke60od – nipro May 29 '18 at 9:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.