Ricardo ACB
Ricardo ACB

Reputation: 268

Select Feature Control OpenLayers

I've been working with OpenLayers, and i made a layer tree (all layers are vector layers), and all this layers have features, what i want is to select those features through the select control.

I made the Select Feature Control but the problem it's that when i turn off one of those layers(i'm removing the layer from the map to turn it off), the icon still there, it's like it doesn't turned off at all...

I've tryed almost everything and i don't know why this could be happening...

Does anybody know how to solve this???

Upvotes: 3

Views: 657

Answers (1)

danielrvt
danielrvt

Reputation: 10926

You could just remove all features from the layer each time you deactivate your control enstead of removing the layer.

Upvotes: 4

Related Questions