Exemplo n.º 1
0
 public void addTrItem(TrackSegment tr)
 {
     if (tr != null)
     {
         trItems.Add(tr);
     }
 }
Exemplo n.º 2
0
 public void DefineAsInterface(TrackSegment segment)
 {
     typeWidget = (int)TypeWidget.STATION_INTERFACE;
     if (stationConnector == null)
     {
         stationConnector = new StationConnector(segment);
     }
     stationConnector.Init(segment);
     setLineSnap();
     setEditable();
 }
Exemplo n.º 3
0
 public StationConnector(TrackSegment segment)
 {
     File.AppendAllText(@"F:\temp\AE.txt", "StationConnector\n");
     parentSegment     = segment;
     allowedDirections = new List <string>();
     allowedDirections.Add("   ");
     allowedDirections.Add("In");
     allowedDirections.Add("Out");
     allowedDirections.Add("Both");
     dirConnector = AllowedDir.NONE;
     configured   = false;
 }
Exemplo n.º 4
0
        public void AddSegment(TrackSegment line)
        {
            PointF lineA = line.A.ConvertToPointF();
            PointF lineB = line.B.ConvertToPointF();

            if (lineA == lineB)
            {
                return;
            }
            foreach (var segment in segments)
            {
                PointF segmentA = segment.A.ConvertToPointF();
                PointF segmentB = segment.B.ConvertToPointF();
                if (lineA == segmentA && lineB == segmentB)
                {
                    return;
                }
                if (lineA == segmentB && lineB == segmentA)
                {
                    return;
                }
            }
            segments.Add(line);
        }
Exemplo n.º 5
0
 public void Init(TrackSegment info)
 {
     segment   = info;
     idxMaster = info.SectionIdxA;
     idxSecond = info.SectionIdxB;
 }
Exemplo n.º 6
0
 public override void Update(MSTSCoord coord, TrackSegment segment)
 {
     base.configCoord(coord);
 }
Exemplo n.º 7
0
 public virtual void Update(MSTSCoord coord, TrackSegment segment)
 {
 }