mirror of
https://github.com/FoggedLens/iD.git
synced 2026-02-14 17:52:55 +00:00
9 lines
347 B
JavaScript
9 lines
347 B
JavaScript
// https://github.com/openstreetmap/potlatch2/blob/master/net/systemeD/halcyon/connection/actions/AddNodeToWayAction.as
|
|
iD.actions.ReverseWay = function(wayId) {
|
|
return function(graph) {
|
|
var way = graph.entity(wayId),
|
|
nodes = way.nodes.slice().reverse();
|
|
return graph.replace(way.update({nodes: nodes}));
|
|
};
|
|
};
|