public void InitializeVariableTextBoxes(CompressorControl ctrl) { this.textBoxPressureRatio.InitializeVariable(ctrl.Flowsheet.ApplicationPrefs, ctrl.Compressor.OutletInletPressureRatio); this.textBoxAdiabaticExponent.InitializeVariable(ctrl.Flowsheet.ApplicationPrefs, ctrl.Compressor.AdiabaticExponent); this.textBoxAdiabaticEfficiency.InitializeVariable(ctrl.Flowsheet.ApplicationPrefs, ctrl.Compressor.AdiabaticEfficiency); this.textBoxPolytropicExponent.InitializeVariable(ctrl.Flowsheet.ApplicationPrefs, ctrl.Compressor.PolytropicExponent); this.textBoxPolytropicEfficiency.InitializeVariable(ctrl.Flowsheet.ApplicationPrefs, ctrl.Compressor.PolytropicEfficiency); this.textBoxPowerInput.InitializeVariable(ctrl.Flowsheet.ApplicationPrefs, ctrl.Compressor.PowerInput); }
public CompressorValuesControl(CompressorControl compressorCtrl) : this() { this.inConstruction = true; this.compressorCtrl = compressorCtrl; this.InitializeVariableTextBoxes(compressorCtrl); this.compressorCtrl.Compressor.SolveComplete += new SolveCompleteEventHandler(Compressor_SolveComplete); this.comboBoxCompressionProcess.SelectedIndex = -1; this.inConstruction = false; this.SetCompressionProcess(compressorCtrl.Compressor.CompressionProcess); }
public CompressorEditor(CompressorControl compressorCtrl) : base(compressorCtrl) { // // Required for Windows Form Designer support // //InitializeComponent(); Compressor compressor = this.CompressorCtrl.Compressor; this.Text = "Compressor: " + compressor.Name; //this.groupBoxTwoStreamUnitOp.Size = new System.Drawing.Size(280, 180); //this.groupBoxTwoStreamUnitOp.Text = "Compressor"; //CompressorLabelsControl compressorLabelsCtrl = new CompressorLabelsControl(this.CompressorCtrl.Compressor); //this.groupBoxTwoStreamUnitOp.Controls.Add(compressorLabelsCtrl); //compressorLabelsCtrl.Location = new Point(4, 12 + 20 + 2); //CompressorValuesControl compressorValuesCtrl = new CompressorValuesControl(this.CompressorCtrl); //this.groupBoxTwoStreamUnitOp.Controls.Add(compressorValuesCtrl); //compressorValuesCtrl.Location = new Point(196, 12 + 20 + 2); initializeGrid(compressorCtrl, columnIndex, false, "Compressor"); }