tbf/TBF/Rig/TestMethods/StandingStartMassCollectionPoseidon/HeatMeters/TestMethodCfgCtrl.cs
Michal Buzik c3c21649fb new Test method Poseidon => StandingStartMassCollectionPoseidon
Add support for `StandingStartMassCollectionPoseidon` test methods.

- Introduced `Compound`, `HeatMeters`, and `Single` components for `StandingStartMassCollectionPoseidon`.
- Included factories, configuration classes, and test parameters for new test methods.
- Updated `TBF.csproj` to include new files and resources.
2025-11-12 13:42:19 +01:00

71 lines
1.4 KiB
C#

///
/// Copyright (c) 2013-2016 Sensus Metering Systems
///
using System;
using System.Windows.Forms;
using Common;
using TBF.Rig.Generic;
namespace TBF.Rig.TestMethods.StandingStartMassCollectionPoseidon.HeatMeters
{
public partial class TestMethodCfgCtrl : UserControl, IComponentCfgCtrl
{
public bool ShowMore { get { return false; } }
StandingStartMassCollection.HeatMeters.TestMethodCfg config;
public IComponentCfg Config
{
get { return config as IComponentCfg; }
set
{
config = value as StandingStartMassCollection.HeatMeters.TestMethodCfg;
Redraw();
}
}
public TestMethodCfgCtrl()
{
InitializeComponent();
}
private void EntryFormCfgCtrl_Load(object sender, EventArgs e)
{
Redraw();
}
public void Closing()
{
}
void Redraw()
{
if (config == null) return; /// Control was not loaded, settings were not changed
classNameLabel.Text = config.Factory.ClassName;
nameTextBox.Text = config.Name;
}
public void Unlock()
{
nameTextBox.Enabled = true;
}
public CfgUpdateFlags VerifyCfg(ref string message)
{
CfgUpdateFlags flags = CfgUpdateFlags.None;
return flags;
}
public CfgUpdateFlags UpdateCfg()
{
CfgUpdateFlags flags = CfgUpdateFlags.RestartRqrd;
if (config == null) return CfgUpdateFlags.Error; /// Control was not loaded, settings were not changed
config.Name = nameTextBox.Text;
return flags;
}
}
}