Commit 24f8f507 authored by 潘栩锋's avatar 潘栩锋 🚴

删掉NotifyPropertyChanged()

parent fc6802d9
...@@ -13,80 +13,27 @@ namespace FLY.Thick.Blowing.Client ...@@ -13,80 +13,27 @@ namespace FLY.Thick.Blowing.Client
{ {
#region IRenZiJiaService 成员 #region IRenZiJiaService 成员
#region 膜长 计算 #region 膜长 计算
private double flrange;
/// <summary> /// <summary>
/// 膜长查找范围, 以FilmLength为目标值,两边查找,单位m /// 膜长查找范围, 以FilmLength为目标值,两边查找,单位m
/// </summary> /// </summary>
public double FLRange public double FLRange { get; set; }
{
get { return flrange; }
set
{
if (flrange != value)
{
flrange = value;
NotifyPropertyChanged("FLRange");
}
}
}
private string calstate;
/// <summary> /// <summary>
/// 计算的状态,因为是一个很漫长的过程!!! /// 计算的状态,因为是一个很漫长的过程!!!
/// </summary> /// </summary>
public string CalState public string CalState { get; set; }
{
get { return calstate; }
protected set
{
if (calstate != value)
{
calstate = value;
NotifyPropertyChanged("CalState");
}
}
}
#region 计算结果 #region 计算结果
private double maxr;
/// <summary> /// <summary>
/// 最大相识度 /// 最大相识度
/// </summary> /// </summary>
public double MaxR public double MaxR { get; set; }
{
get
{
return maxr;
}
set
{
if (maxr != value)
{
maxr = value;
NotifyPropertyChanged("MaxR");
}
}
}
private double maxrfilmlength;
/// <summary> /// <summary>
/// 最大相识度对应速度 /// 最大相识度对应速度
/// </summary> /// </summary>
public double MaxRFilmLength public double MaxRFilmLength { get; set; }
{
get
{
return maxrfilmlength;
}
set
{
if (maxrfilmlength != value)
{
maxrfilmlength = value;
NotifyPropertyChanged("MaxRFilmLength");
}
}
}
#endregion #endregion
#endregion #endregion
...@@ -95,153 +42,45 @@ namespace FLY.Thick.Blowing.Client ...@@ -95,153 +42,45 @@ namespace FLY.Thick.Blowing.Client
/// <summary> /// <summary>
/// 追边开始按钮自锁 /// 追边开始按钮自锁
/// </summary> /// </summary>
public bool IsBtnSelfHold public bool IsBtnSelfHold { get; set; }
{
get
{
return isBtnSelfHold;
}
set
{
if (isBtnSelfHold != value)
{
isBtnSelfHold = value;
NotifyPropertyChanged("IsBtnSelfHold");
}
}
}
RenZiJiaFixEPCType epctype = RenZiJiaFixEPCType.Null;
public RenZiJiaFixEPCType EPCType
{
get
{
return epctype;
}
set
{
if (epctype != value)
{
epctype = value;
NotifyPropertyChanged("EPCType");
}
}
}
TimeSpan sampleconsume = TimeSpan.FromSeconds(2); public RenZiJiaFixEPCType EPCType { get; set; }
/// <summary> /// <summary>
/// 采样时间, 默认2s /// 采样时间, 默认2s
/// </summary> /// </summary>
public TimeSpan SampleConsume public TimeSpan SampleConsume { get; set; } = TimeSpan.FromSeconds(2);
{
get { return sampleconsume; }
set
{
if (sampleconsume != value)
{
sampleconsume = value;
NotifyPropertyChanged("SampleConsume");
}
}
}
TimeSpan sampleinterval = TimeSpan.FromMinutes(45);
/// <summary> /// <summary>
/// 温修间隔,默认45分钟 /// 温修间隔,默认45分钟
/// </summary> /// </summary>
public TimeSpan SampleInterval public TimeSpan SampleInterval { get; set; } = TimeSpan.FromMinutes(45);
{
get { return sampleinterval; }
set
{
if (sampleinterval != value)
{
sampleinterval = value;
NotifyPropertyChanged("SampleInterval");
}
}
}
TimeSpan sampletimer = TimeSpan.Zero;
/// <summary> /// <summary>
/// 当前温修计时,大于温修间隔就会去温修 /// 当前温修计时,大于温修间隔就会去温修
/// </summary> /// </summary>
public TimeSpan SampleTimer public TimeSpan SampleTimer { get; protected set; } = TimeSpan.Zero;
{
get
{
return sampletimer;
}
protected set
{
if (sampletimer != value)
{
sampletimer = value;
NotifyPropertyChanged("SampleTimer");
}
}
}
TimeSpan backedgewait = TimeSpan.FromSeconds(5);
/// <summary> /// <summary>
/// 回到边界后,再等待一段时间,那就肯定找到边界了。 默认5s /// 回到边界后,再等待一段时间,那就肯定找到边界了。 默认5s
/// </summary> /// </summary>
public TimeSpan BackEdgeWait public TimeSpan BackEdgeWait { get; set; } = TimeSpan.FromSeconds(5);
{
get
{
return backedgewait;
}
set
{
if (backedgewait != value)
{
backedgewait = value;
NotifyPropertyChanged("BackEdgeWait");
}
}
}
private int samplead = -1;
/// <summary> /// <summary>
/// 采样得到的样品AD /// 采样得到的样品AD
/// </summary> /// </summary>
public int SampleAD public int SampleAD { get; protected set; } = -1;
{
get
{
return samplead;
}
protected set
{
if (samplead != value)
{
samplead = value;
NotifyPropertyChanged("SampleAD");
}
}
}
bool epcisrunning = false;
/// <summary> /// <summary>
/// 追边运行中! /// 追边运行中!
/// </summary> /// </summary>
public bool EPCIsRunning public bool EPCIsRunning { get; set; }
{
get
{
return epcisrunning;
}
protected set
{
if (epcisrunning != value)
{
epcisrunning = value;
NotifyPropertyChanged("EPCIsRunning");
}
}
}
#endregion #endregion
#endregion #endregion
......
...@@ -14,63 +14,20 @@ namespace FLY.Thick.Blowing.Client ...@@ -14,63 +14,20 @@ namespace FLY.Thick.Blowing.Client
protected IFConn mConn; protected IFConn mConn;
protected UInt32 mServerID; protected UInt32 mServerID;
private bool isconnected = false; public bool IsConnected { get; set; }
public bool IsConnected
{
get { return isconnected; }
set
{
if (isconnected != value)
{
isconnected = value;
NotifyPropertyChanged("IsConnected");
}
}
}
#region IBlowing 成员变量 #region IBlowing 成员变量
#region 分区设定 #region 分区设定
private int channelcnt = 44;
/// <summary> /// <summary>
/// 加热通道数 /// 加热通道数
/// </summary> /// </summary>
public int ChannelCnt public int ChannelCnt { get; set; } = 44;
{
get
{
return channelcnt;
}
set
{
if (channelcnt != value)
{
channelcnt = value;
NotifyPropertyChanged("ChannelCnt");
NotifyPropertyChanged("NBolts");
}
}
}
private int bpc = 2;
/// <summary> /// <summary>
/// 分区数/加热通道数 /// 分区数/加热通道数
/// </summary> /// </summary>
public int BPC public int BPC { get; set; } = 2;
{
get
{
return bpc;
}
set
{
if (bpc != value)
{
bpc = value;
NotifyPropertyChanged("BPC");
NotifyPropertyChanged("NBolts");
}
}
}
/// <summary> /// <summary>
...@@ -83,52 +40,19 @@ namespace FLY.Thick.Blowing.Client ...@@ -83,52 +40,19 @@ namespace FLY.Thick.Blowing.Client
public int OrgBoltNo { get; set; } = 1;
private int orgboltno = 1;
public int OrgBoltNo
{
get
{
return orgboltno;
}
set
{
if (orgboltno != value)
{
orgboltno = value;
NotifyPropertyChanged("OrgBoltNo");
}
}
}
private bool isUsedMap = false;
/// <summary> /// <summary>
/// 使用分区表 /// 使用分区表
/// </summary> /// </summary>
public bool IsUsedMap public bool IsUsedMap { get; set; }
{
get { return isUsedMap; }
set {
if (isUsedMap != value)
{
isUsedMap = value;
NotifyPropertyChanged("IsUsedMap");
}
}
}
private List<BoltMapCell> map = new List<BoltMapCell>();
/// <summary> /// <summary>
/// 分区表 /// 分区表
/// </summary> /// </summary>
public List<BoltMapCell> Map public List<BoltMapCell> Map { get; set; } = new List<BoltMapCell>();
{
get { return map; }
set {
map = value;
NotifyPropertyChanged("Map");
}
}
#endregion #endregion
...@@ -171,11 +95,7 @@ namespace FLY.Thick.Blowing.Client ...@@ -171,11 +95,7 @@ namespace FLY.Thick.Blowing.Client
#region INotifyPropertyChanged 成员 #region INotifyPropertyChanged 成员
protected void NotifyPropertyChanged(string propertyName)
{
if (PropertyChanged != null)
PropertyChanged.Invoke(this, new PropertyChangedEventArgs(propertyName));
}
public event PropertyChangedEventHandler PropertyChanged; public event PropertyChangedEventHandler PropertyChanged;
#endregion #endregion
......
...@@ -166,7 +166,7 @@ namespace FLY.Weight.Server ...@@ -166,7 +166,7 @@ namespace FLY.Weight.Server
RollMixBuffer.Add(w, new BufferStorage<FlyData_Mix>(w.Number + "_rollmixbuffer.csv", 1, 400)); RollMixBuffer.Add(w, new BufferStorage<FlyData_Mix>(w.Number + "_rollmixbuffer.csv", 1, 400));
} }
//-------------------------------------------------------------------------------- //--------------------------------------------------------------------------------
//Test(); Test();
plcos.Init(); plcos.Init();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment