public override void InitAfterLoad(Layout l) { this.m_Station = l.Stations.GetStationByID(this.m_strStation); Debug.Assert(this.m_Station != null); Debug.Assert(this.m_strAPIID != "?"); base.InitAfterLoad(l); }
public Perron() { this.m_strStation = ""; this.m_nTrainHeadStopPositionLatitude = 0M; this.m_nTrainHeadStopPositionLongitude = 0M; this.m_nDistance = 0; this.m_nNumber = 1; this.m_nEscapement = 0; this.Enabled = true; this.TrackSource = -1; this.Track = null; this.m_Station = null; this.Displays = new ArrayList(); this.Caption = ""; this.CaptionColor = Colors.get_Black(); this.Init(); }
public Perron(string strID) : base(strID) { this.m_strStation = ""; this.m_nTrainHeadStopPositionLatitude = 0M; this.m_nTrainHeadStopPositionLongitude = 0M; this.m_nDistance = 0; this.m_nNumber = 1; this.m_nEscapement = 0; this.Enabled = true; this.TrackSource = -1; this.Track = null; this.m_Station = null; this.Displays = new ArrayList(); this.Caption = ""; this.CaptionColor = Colors.get_Black(); this.Init(); }
public override void InitAfterLoad(Layout l) { string[] strArray = this.m_strPerronIDs.Split(new char[] { ';' }); this.m_Station = l.Stations.GetStationByID(this.m_strStation); Debug.Assert(this.m_Station != null); if (this.m_Station != null) { foreach (string str in strArray) { Perron perronByID = this.m_Station.GetPerronByID(str); Debug.Assert(perronByID != null); if (perronByID != null) { this.Perrons.Add(perronByID); this.m_PerronNumbers.Add(perronByID.Number); perronByID.Displays.Add(this); } } if (this.m_PerronNumbers.Count != this.m_Station.m_Perrons.Count) { ArrayList list = new ArrayList(); foreach (int num in this.m_PerronNumbers) { if (!list.Contains(num)) { if (this.TrackFilter.Length > 0) { this.TrackFilter = this.TrackFilter + " OR "; } this.TrackFilter = this.TrackFilter + string.Format("TrackNo={0}", num); list.Add(num); } } } } base.InitAfterLoad(l); }