From 715f3c968e06bce3a603925f30f7cfdd68f71e6c Mon Sep 17 00:00:00 2001 From: portree_kid Date: Fri, 28 Aug 2020 22:02:13 +0200 Subject: [PATCH] Snap to --- src/renderer/components/EditLayer.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/renderer/components/EditLayer.vue b/src/renderer/components/EditLayer.vue index 3884cf1..dd99afe 100644 --- a/src/renderer/components/EditLayer.vue +++ b/src/renderer/components/EditLayer.vue @@ -788,7 +788,7 @@ You should have received a copy of the GNU General Public License along with FG console.warn('No glueindex : ' + latlng.__vertex); } let distance = latlng.distanceTo(eventLatlng) - if (distance > 0 && distance < snap) { + if (distance >= 0 && distance < snap && latlng.glueindex >=0) { layers.push({d: distance, l: layer, latlng: latlng.__vertex.latlng, glueindex: latlng.glueindex}) } } else {