Don't open tooltip after DrawWay

(as we'll be going straight into tag editor)
This commit is contained in:
Richard Fairhurst
2012-07-12 07:40:26 +01:00
parent 3ab962f329
commit 04f31995d2
3 changed files with 4 additions and 4 deletions

View File

@@ -24,7 +24,7 @@ declare("iD.controller.edit.EditBaseState", [iD.controller.ControllerState], {
},
closeEditorTooltip:function() {
dijit.popup.close(editortooltip);
if (this.editortooltip) { dijit.popup.close(editortooltip); }
},
});

View File

@@ -19,7 +19,7 @@ declare("iD.controller.edit.SelectedWay", [iD.controller.edit.EditBaseState], {
this.wayUI=this.controller.map.getUI(this.way);
this.wayUI.setStateClass('selected');
this.wayUI.setStateClass('shownodes');
this.openEditorTooltip(this.entryevent.clientX, this.entryevent.clientY);
if (this.entryevent) { this.openEditorTooltip(this.entryevent.clientX, this.entryevent.clientY); }
this.wayUI.redraw();
},
exitState:function() {

View File

@@ -94,12 +94,12 @@ declare("iD.controller.shape.DrawWay", [iD.controller.ControllerState], {
if (entity==this.getDrawingNode()) {
// Double-click, so complete drawing
this.controller.stepper.highlight('tag');
return new iD.controller.edit.SelectedWay(this.way, event);
return new iD.controller.edit.SelectedWay(this.way, null);
} else if (entity==this.getStartNode()) {
// Start of this way, so complete drawing
this.appendNode(entity, this.undoAdder() );
this.controller.stepper.highlight('tag');
return new iD.controller.edit.SelectedWay(this.way, event);
return new iD.controller.edit.SelectedWay(this.way, null);
} else {
// Add to way
this.appendNode(entity, this.undoAdder() );