Skip to content

Commit

Permalink
fix: fix startMarker/Polyline/Polygon on right click (#2403)
Browse files Browse the repository at this point in the history
fix #2392
  • Loading branch information
yohanboniface authored Dec 26, 2024
2 parents da78ac0 + ed33b16 commit 48ae412
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions umap/static/umap/js/modules/umap.js
Original file line number Diff line number Diff line change
Expand Up @@ -349,19 +349,19 @@ export default class Umap extends ServerStored {
if (this.properties.enableMarkerDraw) {
items.push({
label: this.help.displayLabel('DRAW_MARKER'),
action: () => this._leafletMap.startMarker(event),
action: () => this._leafletMap.editTools.startMarker(),
})
}
if (this.properties.enablePolylineDraw) {
items.push({
label: this.help.displayLabel('DRAW_POLYGON'),
action: () => this._leafletMap.startPolygon(event),
action: () => this._leafletMap.editTools.startPolygon(),
})
}
if (this.properties.enablePolygonDraw) {
items.push({
label: this.help.displayLabel('DRAW_LINE'),
action: () => this._leafletMap.startPolyline(event),
action: () => this._leafletMap.editTools.startPolyline(),
})
}
items.push('-')
Expand Down

0 comments on commit 48ae412

Please sign in to comment.