Beispiel #1
0
 public void HookEndPointToFigure(Point e)
 {
     if (DataCommon.Count == 0)
     {
         DataCommon.Add(new DataCommon(this));
     }
     if (!(DataCommon[0].LastBox is null))
     {
         DataCommon[0].LastBox.DataCommon.Remove(DataCommon[0]);
         DataCommon[0].LastBox   = null;
         DataCommon[0].LastPoint = null;
     }
     foreach (IFigure figure in CoreUML.GetCoreUML().Figures)
     {
         if (figure is AbstractBox abstractBox && figure != DataCommon[0].FirstBox)
         {
             if (figure.CheckSelection(e, e, 7))
             {
                 DataCommon[0].LastBox   = abstractBox;
                 DataCommon[0].LastPoint = abstractBox.GetConnectionPoint(e, Points[0]);
                 EndDirectionAxis        = DataCommon[0].LastPoint.Axis;
                 GetPoints(Points[0], abstractBox.GetCordinatsOfConnectionPoint(DataCommon[0].LastPoint));
                 abstractBox.DataCommon.Add(DataCommon[0]);
                 return;
             }
         }
     }
     GetPoints(Points[0], e);
 }
Beispiel #2
0
 public void WriteCommonPoints(DataCommon dataPoints)
 {
     DataCommon.Add(dataPoints);
 }