Fix shift-clicking issue
authorRichard Fairhurst <richard@systemeD.net>
Thu, 4 Oct 2012 21:15:59 +0000 (22:15 +0100)
committerRichard Fairhurst <richard@systemeD.net>
Thu, 4 Oct 2012 21:15:59 +0000 (22:15 +0100)
net/systemeD/potlatch2/controller/SelectedWay.as

index 1460ff0..a40070e 100644 (file)
@@ -49,7 +49,7 @@ package net.systemeD.potlatch2.controller {
                        var paint:MapPaint = getMapPaint(DisplayObject(event.target));
             var focus:Entity = getTopLevelFocusEntity(entity);
 
-            if ( event.type == MouseEvent.MOUSE_DOWN && entity is Node && focus==firstSelected && event.shiftKey && !layer.isBackground ) {
+            if ( event.type == MouseEvent.MOUSE_DOWN && entity is Node && entity.hasParent(firstSelected) && event.shiftKey && !layer.isBackground ) {
                                // start new way
                                var way:Way = entity.connection.createWay({}, [entity], MainUndoStack.getGlobalStack().addAction);
                                return new DrawWay(way, true, false);