public MainWindow() { dbManager = new DBManager(); //Create the component info control componentInfoControl = new componentInfoUserControl(this, dbManager); componentInfoControl.Location = new System.Drawing.Point(9, 428); //Create the component tree control treeControl = new componentTreeUserControl(this, componentInfoControl, dbManager); treeControl.Location = new System.Drawing.Point(9, 6); //Set the info panel to use the TreeUserControl being used by the Main Window componentInfoControl.setTreeControl(treeControl); //Create a default aircraft layout and add it to the middle panel aircraftControl = new SinglePropellerLayout(this, treeControl); aircraftControl.Location = new Point(10, 10); InitializeComponent(); //Add controls to their appropriate containers splitContainer1.Panel1.Controls.Add(treeControl); splitContainer1.Panel1.Controls.Add(componentInfoControl); splitContainer1.Panel2.Controls.Add(aircraftControl); }
public AircraftLayoutControl(MainWindow mainWindow, componentTreeUserControl treeControl) { this.mainWindow = mainWindow; this.treeControl = treeControl; sockets = new List<Socket.Socket>(); InitializeComponent(); }
public void setTreeControl(componentTreeUserControl treeControl) { this.treeControl = mainWindow.getTreeControl(); }
public SinglePropellerLayout(MainWindow mainWindow, componentTreeUserControl treeControl) : base(mainWindow, treeControl) { InitializeComponent(); setUpSockets(); }