Nested Layer Control?

371 views
Skip to first unread message

Ricky Satomi

unread,
Jun 11, 2015, 1:54:52 PM6/11/15
to leafl...@googlegroups.com
Is there a way to have nested layer control options?
Possibly through linking layergroups with the individual layers

The objective is to display data in a more organized manner. In theory, selecting the "fast food places" layer would activate all tree sublayers. The user could then turn off the "mcdonalds" and "jack in the box"  layer to just show the "burger king" layer.

Fast Food Places
- Mcdonalds
- Burger King
- Jack in the Box

Brendan Stone

unread,
Jun 13, 2015, 7:05:13 AM6/13/15
to leafl...@googlegroups.com
This plugin is half way there:

You could probably modify it so there is a checkbox next to "Random" and "Landmarks" (in their example) which would switch on/off the sub layers.

Alternatively, create a layerGroup with all your fast food layers and add it to layer control. 
Then add some checkboxes for each restaurant which add/remove these layers from the layerGroup.
Reply all
Reply to author
Forward
0 new messages