mirror of
https://github.com/FoggedLens/iD.git
synced 2026-05-20 15:34:49 +02:00
Remove controller.exit
This commit is contained in:
@@ -32,7 +32,7 @@ iD.behavior.AddWay = function(mode) {
|
||||
};
|
||||
|
||||
addWay.cancel = function() {
|
||||
controller.exit();
|
||||
controller.enter(iD.modes.Browse());
|
||||
};
|
||||
|
||||
return d3.rebind(addWay, event, 'on');
|
||||
|
||||
@@ -19,9 +19,5 @@ iD.Controller = function(map, history) {
|
||||
event.enter(mode);
|
||||
};
|
||||
|
||||
controller.exit = function() {
|
||||
controller.enter(iD.modes.Browse());
|
||||
};
|
||||
|
||||
return d3.rebind(controller, event, 'on');
|
||||
};
|
||||
|
||||
@@ -32,7 +32,7 @@ iD.modes.AddPoint = function() {
|
||||
}
|
||||
|
||||
function cancel() {
|
||||
controller.exit();
|
||||
controller.enter(iD.modes.Browse());
|
||||
}
|
||||
|
||||
behavior = iD.behavior.Draw(map)
|
||||
|
||||
@@ -86,7 +86,7 @@ iD.modes.Select = function(selection, initial) {
|
||||
|
||||
inspector
|
||||
.on('changeTags', changeTags)
|
||||
.on('close', function() { mode.controller.exit(); });
|
||||
.on('close', function() { mode.controller.enter(iD.modes.Browse()); });
|
||||
|
||||
history.on('change.select', function() {
|
||||
// Exit mode if selected entity gets undone
|
||||
|
||||
Reference in New Issue
Block a user