public HubControl(Hub hub) { Hub = hub; Hub.PortTypeUpdated += RefreshUI; Hub.DataUpdated += UpdateLabels; Editor = new HubEditor(Hub); InitializeComponent(); InitControl(); }
//modified by Tom Cook for MU function to add TrainProject project to class where need to loop thru all hubs and ports //public HubControl(Hub hub) public HubControl(Hub hub, TrainProject project) { Hub = hub; Hub.PortTypeUpdated += RefreshUI; Hub.DataUpdated += UpdateLabels; //modified by Tom Cook, see above //Editor = new HubEditor(Hub); Editor = new HubEditor(Hub, project); //added by Tom Cook, see above Project = project; InitializeComponent(); InitControl(); }