Update MapPaint to redraw node if the UI already existed - e.g. redoing a new POI.
authorAndy Allan <gravitystorm@gmail.com>
Wed, 25 Aug 2010 13:35:46 +0000 (13:35 +0000)
committerAndy Allan <gravitystorm@gmail.com>
Wed, 25 Aug 2010 13:35:46 +0000 (13:35 +0000)
net/systemeD/halcyon/MapPaint.as

index d386b1b..8b1faf0 100644 (file)
@@ -137,10 +137,14 @@ package net.systemeD.halcyon {
                        return wayuis[way.id];
                }
 
-               public function createNodeUI(node:Node):NodeUI {
-                       if (!nodeuis[node.id]) { nodeuis[node.id]=new NodeUI(node,this,0); }
-                       return nodeuis[node.id];
-               }
+        public function createNodeUI(node:Node):NodeUI {
+            if (!nodeuis[node.id]) {
+              nodeuis[node.id]=new NodeUI(node,this,0);
+            } else {
+              nodeuis[node.id].redraw();
+            }
+            return nodeuis[node.id];
+        }
 
                public function deleteWayUI(way:Way):void {
                        if (!wayuis[way.id]) { return; }