Add way extending by clicking on first/last node
[potlatch2.git] / net / systemeD / potlatch2 / controller / DragWayNode.as
index 30387b8e0e41677d1c5b65e9d69fe713da4c0049..b2e2668b26e0d16384fa5cb39fd06f4574bb0b3b 100644 (file)
@@ -35,13 +35,13 @@ package net.systemeD.potlatch2.controller {
                                } else if (event.shiftKey && !isNew) {
                                        // start new way
                                        var way:Way = controller.connection.createWay({}, [entity]);
-                                       return new DrawWay(way, true);
+                                       return new DrawWay(way, true, false);
                                } else if (event.shiftKey && isNew) {
                        return new SelectedWayNode(selectedWay,draggingNode);
                                } else {
                                        // select node
                                        dragstate=NOT_DRAGGING;
-                       return new SelectedWayNode(selectedWay,draggingNode);
+                       return SelectedWayNode.selectOrEdit(selectedWay, draggingNode);
                                }
 
                        } else if ( event.type == MouseEvent.MOUSE_MOVE) {