Update dupes when node is moved / deleted. Needs further refactoring
[potlatch2.git] / net / systemeD / halcyon / connection / Entity.as
index bd786fe3de38b195fcceb50a90b03f21a8fecae6..392a890a16d622ac5d7a67b6637ed2953436220c 100644 (file)
@@ -143,6 +143,12 @@ package net.systemeD.halcyon.connection {
                
                public function setDeletedState(isDeleted:Boolean):void {
                    deleted = isDeleted;
+            if (this is Node) {
+              var n:Node = Node(this);
+              Connection.getConnection().removeDupe(n);
+            } else if (this is Node) {
+              Connection.getConnection().addDupe(n.id, n.lat, n.lon);
+            }
                }
                
                internal function isEmpty():Boolean {