From 63f4abb3ef8391c65e312b9feb8ad89f009ae80f Mon Sep 17 00:00:00 2001 From: fkloft Date: Wed, 11 Dec 2013 00:00:04 +0100 Subject: [PATCH] Make user location appear in layer chooser --- mobile/plugins/user-location.user.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/mobile/plugins/user-location.user.js b/mobile/plugins/user-location.user.js index 28395569..b7bfe412 100644 --- a/mobile/plugins/user-location.user.js +++ b/mobile/plugins/user-location.user.js @@ -48,8 +48,11 @@ window.plugin.userLocation.setup = function() { clickable: false }); - marker.addTo(window.map); - circle.addTo(window.map); + marker.addTo(window.plugin.userLocation.locationLayer); + circle.addTo(window.plugin.userLocation.locationLayer); + window.plugin.userLocation.locationLayer.addTo(window.map); + window.addLayerGroup('User location', window.plugin.userLocation.locationLayer, true); + var container = $(".container", marker._icon); window.plugin.userLocation.marker = marker;