fix indicator
This commit is contained in:
parent
9215e39131
commit
1aa724e7fc
1 changed files with 9 additions and 8 deletions
|
@ -2076,17 +2076,18 @@ editor = {
|
||||||
_show_snap_indicator: function(latlng, snapInfo) {
|
_show_snap_indicator: function(latlng, snapInfo) {
|
||||||
editor._clear_snap_indicators();
|
editor._clear_snap_indicators();
|
||||||
|
|
||||||
// snap point indicator
|
var size = 0.001;
|
||||||
var indicator = L.circleMarker(latlng, {
|
var bounds = [
|
||||||
radius: 4,
|
[latlng.lat - size, latlng.lng - size],
|
||||||
color: '#ff6b6b',
|
[latlng.lat + size, latlng.lng + size]
|
||||||
fillColor: '#ff6b6b',
|
];
|
||||||
fillOpacity: 0.8,
|
var indicator = L.rectangle(bounds, {
|
||||||
|
color: '#666',
|
||||||
weight: 2,
|
weight: 2,
|
||||||
lineCap: "square",
|
lineCap: "square",
|
||||||
fillOpacity: 1.,
|
fillOpacity: 1.,
|
||||||
className: 'snap-indicator'
|
className: 'snap-indicator'
|
||||||
});
|
});
|
||||||
|
|
||||||
editor._snap_indicator.addLayer(indicator);
|
editor._snap_indicator.addLayer(indicator);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue