Properly closing popups again on second click

before-leaflet
Candid Dauth 2016-10-04 16:54:25 +03:00
rodzic f6cb4bbe24
commit eb2ecc9d2e
2 zmienionych plików z 2 dodań i 2 usunięć

Wyświetl plik

@ -154,7 +154,7 @@
map.mapEvents.$on("clickLine", function(e, line, clickPos, evt) {
var one = false;
map.popups.getOpenPopups().forEach(function(popup) {
if(popup.template == "view-line.html" && popup.scope.line.id == line.id) {
if(popup.template == "map/lines/view-line.html" && popup.scope.line.id == line.id) {
popup.close();
if(popup.pos.lon == clickPos.lon && popup.pos.lat == clickPos.lat)
one = true;

Wyświetl plik

@ -102,7 +102,7 @@
map.mapEvents.$on("clickMarker", function(e, marker, evt) {
var one = false;
map.popups.getOpenPopups().forEach(function(popup) {
if(popup.template == "view-marker.html" && popup.scope.marker.id == marker.id) {
if(popup.template == "map/markers/view-marker.html" && popup.scope.marker.id == marker.id) {
popup.close();
one = true;
}