IParamsProvider.UpdateParam(...) returns CfgUpdateFlags now.
This commit is contained in:
@@ -97,18 +97,18 @@ namespace TBF.BenchControl.RegisterReaders.SerialStream
|
||||
}
|
||||
}
|
||||
|
||||
public void UpdateParam(int i, string strValue)
|
||||
public CfgUpdateFlags UpdateParam(int i, string strValue)
|
||||
{
|
||||
switch (i)
|
||||
{
|
||||
case 0:
|
||||
for (StreamType st = 0; st < StreamType.Count; st++)
|
||||
{
|
||||
if (st.ToString().Equals(strValue)) { StreamType = st; return; }
|
||||
if (st.ToString().Equals(strValue)) { StreamType = st; return CfgUpdateFlags.None; }
|
||||
}
|
||||
break;
|
||||
case 1: FrameLength = int.Parse(strValue); return;
|
||||
case 2: FrameFrequency = Utils.ParseUDouble(strValue); return;
|
||||
case 1: FrameLength = int.Parse(strValue); return CfgUpdateFlags.None;
|
||||
case 2: FrameFrequency = Utils.ParseUDouble(strValue); return CfgUpdateFlags.None;
|
||||
|
||||
case 3:
|
||||
for (Config.Unit u = 0; u < Config.Unit.Count; u++)
|
||||
@@ -116,17 +116,17 @@ namespace TBF.BenchControl.RegisterReaders.SerialStream
|
||||
if (Config.Units.IsQuantity(u, Config.Quantity.Volume) && u.ToDescription().Equals(strValue))
|
||||
{
|
||||
VolumeUnits = u;
|
||||
return;
|
||||
return CfgUpdateFlags.None;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 4: VolumeScaleFactor = Utils.ParseSDouble(strValue); return;
|
||||
case 5: VolumeFieldStart = int.Parse(strValue); return;
|
||||
case 6: VolumeFieldEnd = int.Parse(strValue); return;
|
||||
case 4: VolumeScaleFactor = Utils.ParseSDouble(strValue); return CfgUpdateFlags.None;
|
||||
case 5: VolumeFieldStart = int.Parse(strValue); return CfgUpdateFlags.None;
|
||||
case 6: VolumeFieldEnd = int.Parse(strValue); return CfgUpdateFlags.None;
|
||||
case 7:
|
||||
for (FieldFormat ff = 0; ff < FieldFormat.Count; ff++)
|
||||
{
|
||||
if (ff.ToString().Equals(strValue)) { VolumeFieldFormat = ff; return; }
|
||||
if (ff.ToString().Equals(strValue)) { VolumeFieldFormat = ff; return CfgUpdateFlags.None; }
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -136,22 +136,24 @@ namespace TBF.BenchControl.RegisterReaders.SerialStream
|
||||
if (Config.Units.IsQuantity(u, Config.Quantity.Time) && u.ToDescription().Equals(strValue))
|
||||
{
|
||||
TimeUnits = u;
|
||||
return;
|
||||
return CfgUpdateFlags.None;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 9: TimeScaleFactor = Utils.ParseSDouble(strValue); return;
|
||||
case 10: TimeFieldStart = int.Parse(strValue); return;
|
||||
case 11: TimeFieldEnd = int.Parse(strValue); return;
|
||||
case 9: TimeScaleFactor = Utils.ParseSDouble(strValue); return CfgUpdateFlags.None;
|
||||
case 10: TimeFieldStart = int.Parse(strValue); return CfgUpdateFlags.None;
|
||||
case 11: TimeFieldEnd = int.Parse(strValue); return CfgUpdateFlags.None;
|
||||
case 12:
|
||||
for (FieldFormat ff = 0; ff < FieldFormat.Count; ff++)
|
||||
{
|
||||
if (ff.ToString().Equals(strValue)) { TimeFieldFormat = ff; return; }
|
||||
if (ff.ToString().Equals(strValue)) { TimeFieldFormat = ff; return CfgUpdateFlags.None; }
|
||||
}
|
||||
break;
|
||||
|
||||
default: return;
|
||||
default: return CfgUpdateFlags.None;
|
||||
}
|
||||
|
||||
return CfgUpdateFlags.None;
|
||||
}
|
||||
|
||||
public bool ValidateParam(int i, string strValue, out string message)
|
||||
|
||||
Reference in New Issue
Block a user