Beispiel #1
0
 /// <summary>
 /// Updates the connection when parent of <see cref="Association"/> changes.
 /// </summary>
 /// <param name="newParent">The new parent.</param>
 public void UpdateConnection(IConnectable newParent)
 {
     ParentRepresentation = newParent;
     ViewHelper.Points.Clear();
     ViewHelper.Points.AppendRange(JunctionGeometryHelper.ComputeOptimalConnection(ParentRepresentation,
                                                                                   ChildRepresentation));
     if (!ChildRepresentation.IsMeasureValid || !ParentRepresentation.IsMeasureValid)
     {
         ViewHelper.Points.PointsInvalid = true;
     }
     Junction.NewConnection(ParentRepresentation, null, ChildRepresentation, null, ViewHelper.Points);
 }