예제 #1
0
        public FanEditor(FanControl fanCtrl) : base(fanCtrl)
        {
            //
            // Required for Windows Form Designer support
            //
            //InitializeComponent();

            int rowCount = 0;

            this.inConstruction = true;

            this.fan  = this.FanCtrl.Fan;
            this.Text = "Fan: " + fan.Name;
            rowCount  = initializeGrid(fanCtrl, columnIndex, false, "Fan");
            //this.groupBoxTwoStreamUnitOp.Size = new System.Drawing.Size(280, 280);
            //this.groupBoxTwoStreamUnitOp.Text = "Fan";

            //FanLabelsControl fanLabelsCtrl = new FanLabelsControl(fanCtrl.Fan);
            //this.groupBoxTwoStreamUnitOp.Controls.Add(fanLabelsCtrl);
            //fanLabelsCtrl.Location = new Point(4, 12 + 20 + 2);

            //FanValuesControl fanValuesCtrl = new FanValuesControl(this.FanCtrl);
            //this.groupBoxTwoStreamUnitOp.Controls.Add(fanValuesCtrl);
            //fanValuesCtrl.Location = new Point(196, 12 + 20 + 2);

            //
            this.checkBoxIncludeDimensions          = new CheckBox();
            this.checkBoxIncludeDimensions.Location = new System.Drawing.Point(4, 118);
            this.checkBoxIncludeDimensions.Name     = "checkBoxIncludeDimensions";
            this.checkBoxIncludeDimensions.Text     = "Include Outlet Velocity Effect";
            //this.groupBoxTwoStreamUnitOp.Controls.Add(this.checkBoxIncludeDimensions);
            this.checkBoxIncludeDimensions.Checked         = this.FanCtrl.Fan.IncludeOutletVelocityEffect;
            this.checkBoxIncludeDimensions.CheckedChanged += new EventHandler(checkBoxIncludeDimensions_CheckedChanged);
            this.checkBoxIncludeDimensions.Size            = new Size(192, 20);
            this.tableLayoutPanel.SetColumnSpan(this.checkBoxIncludeDimensions, 2);
            this.tableLayoutPanel.Controls.Add(this.checkBoxIncludeDimensions, columnIndex, rowCount++);

            //this.checkBoxIncludeDimensions
            this.fanDimensionsCtrl          = new FanDimensionsControl(this.FanCtrl);
            this.fanDimensionsCtrl.Location = new Point(4, 150);
            this.groupBoxTwoStreamUnitOp.Controls.Add(this.fanDimensionsCtrl);
            this.tableLayoutPanel.SetColumnSpan(this.fanDimensionsCtrl, 2);
            this.tableLayoutPanel.SetRowSpan(this.fanDimensionsCtrl, 4);
            this.tableLayoutPanel.Controls.Add(this.fanDimensionsCtrl, columnIndex, rowCount++);

            this.UpdateTheUI();

            this.inConstruction = false;
        }
예제 #2
0
        public FanEditor(FanControl fanCtrl) : base(fanCtrl)
        {
            //
            // Required for Windows Form Designer support
            //
            InitializeComponent();

            this.inConstruction = true;

            this.fan  = this.FanCtrl.Fan;
            this.Text = "Fan: " + fan.Name;

            this.groupBoxTwoStreamUnitOp.Size = new System.Drawing.Size(280, 280);
            this.groupBoxTwoStreamUnitOp.Text = "Fan";

            //ProcessVarLabelsControl fanLabelsCtrl = new ProcessVarLabelsControl(fanCtrl.Fan.VarList);
            FanLabelsControl fanLabelsCtrl = new FanLabelsControl(fanCtrl.Fan);

            this.groupBoxTwoStreamUnitOp.Controls.Add(fanLabelsCtrl);
            fanLabelsCtrl.Location = new Point(4, 12 + 20 + 2);

            //ProcessVarValuesControl fanValuesCtrl = new ProcessVarValuesControl(this.FanCtrl);
            FanValuesControl fanValuesCtrl = new FanValuesControl(this.FanCtrl);

            this.groupBoxTwoStreamUnitOp.Controls.Add(fanValuesCtrl);
            fanValuesCtrl.Location = new Point(196, 12 + 20 + 2);

            //
            this.checkBoxIncludeDimensions          = new CheckBox();
            this.checkBoxIncludeDimensions.Location = new System.Drawing.Point(4, 118);
            this.checkBoxIncludeDimensions.Name     = "checkBoxIncludeDimensions";
            this.checkBoxIncludeDimensions.Text     = "Include Outlet Velocity Effect";
            this.groupBoxTwoStreamUnitOp.Controls.Add(this.checkBoxIncludeDimensions);
            this.checkBoxIncludeDimensions.Checked         = this.FanCtrl.Fan.IncludeOutletVelocityEffect;
            this.checkBoxIncludeDimensions.CheckedChanged += new EventHandler(checkBoxIncludeDimensions_CheckedChanged);
            this.checkBoxIncludeDimensions.Size            = new Size(192, 20);

            this.fanDimensionsCtrl          = new FanDimensionsControl(this.FanCtrl);
            this.fanDimensionsCtrl.Location = new Point(4, 150);
            this.groupBoxTwoStreamUnitOp.Controls.Add(this.fanDimensionsCtrl);

            this.UpdateTheUI();

            this.inConstruction = false;
        }