Defer LayerGroup iteration until snapping phase

This makes it possible to update the contents of the LayerGroup after it has been added as a guide layer. This is useful when the contents are fetched as JSON depending on the map bounds for example.

This is likely to conflict with pull request #4. If this pull request is okay to merge, I suggest to close #4 without merging, since this one includes the fix from #4.