Add reverse route button
This commit is contained in:
parent
79ce49fdb8
commit
d009aa5bc6
3 changed files with 19 additions and 2 deletions
|
|
@ -299,4 +299,11 @@ BR.Routing = L.Routing.extend({
|
|||
,isDrawing: function () {
|
||||
return this._draw._enabled;
|
||||
}
|
||||
|
||||
,reverse: function() {
|
||||
var waypoints = this.getWaypoints();
|
||||
waypoints.reverse();
|
||||
this.clear();
|
||||
this.setWaypoints(waypoints);
|
||||
}
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue