Exemplo n.º 1
0
        public void LoadRoute()
        {
            tagWidgetInfo     = new List <TagWidgetInfo>();
            tagGBList         = new List <GroupBox>();
            stationWidgetInfo = new List <StationWidgetInfo>();
            stationGBList     = new List <GroupBox>();

            Viewer.actParent.SuspendLayout();
            //System.Drawing.Point current = activityAe.GetPanelPosition();
            foreach (var item in getORWidget())
            {
                if (typeof(TagItem) == item.GetType() || item.typeItem == (int)TypeItem.TAG_ITEM)
                {
                    int           cnt          = rnd.Next(999999);
                    TagWidgetInfo newTagWidget = new TagWidgetInfo(Viewer, ((TagItem)item), cnt);
                    AddTagWidgetInfo(newTagWidget);
                }
            }

            foreach (var item in getORWidget())
            {
                if (typeof(StationItem) == item.GetType() || item.typeItem == (int)TypeItem.STATION_AREA_ITEM)
                {
                    int cnt = rnd.Next(999999);
                    StationWidgetInfo newStationWidget = new StationWidgetInfo(Viewer, ((StationItem)item), cnt);
                    AddStationInfo(newStationWidget);
                }
            }
            Viewer.actParent.ResumeLayout(false);
            Viewer.actParent.PerformLayout();
        }
Exemplo n.º 2
0
 public void AddTagWidgetInfo(TagWidgetInfo info)
 {
     tagWidgetInfo.Add(info);
     tagGBList.Add(info.getTag());
     aeRouteConfig.AddTagPanel(tagGBList.ToArray());
 }