黄学彪
2019-10-10 2ed75b8b337048e5d75e6d9ec8307633134f02fd
ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceSearchForm.cs
@@ -130,7 +130,7 @@
            btnProgressView.Text = "0%";
            frameProgress.AddChidren(btnProgressView);
            new System.Threading.Thread(() =>
            HdlThreadLogic.Current.RunThread(() =>
            {
                //蓝才刚说有时候网关会收不到入网的命令,所以发三次
                for (int i = 0; i < 3; i++)
@@ -143,8 +143,7 @@
                    GatewayResourse.NowSelectGateway.AddNewDeviceToGateway(255);
                    System.Threading.Thread.Sleep(1000);
                }
            })
            { IsBackground = true }.Start();
            });
            //添加监视设备新上报的事件
            GatewayResourse.NowSelectGateway.GwResDataAction += this.AdjustGatewayResultData;
@@ -251,7 +250,7 @@
            }
            this.isDeviceThreadStart = true;
            new System.Threading.Thread(() =>
            HdlThreadLogic.Current.RunThread(() =>
            {
                while (this.waitDeviceTimeOut >= 0)
                {
@@ -279,8 +278,7 @@
                        break;
                    }
                });
            })
            { IsBackground = true }.Start();
            });
        }
        /// <summary>
@@ -331,7 +329,7 @@
            btnRound.Y = Application.GetMinRealAverage(475);
            bodyFrameLayout.AddChidren(btnRound);
            new System.Threading.Thread(() =>
            HdlThreadLogic.Current.RunThread(() =>
            {
                int index = 1;
                while (this.Parent != null)
@@ -350,8 +348,7 @@
                        }
                    });
                }
            })
            { IsBackground = true }.Start();
            });
        }
        #endregion
@@ -476,7 +473,7 @@
                return;
            }
            this.isTopicTimeOutThreadStart = true;
            new System.Threading.Thread(() =>
            HdlThreadLogic.Current.RunThread(() =>
            {
                while (this.Parent != null && this.topTimeOut >= 0)
                {
@@ -494,8 +491,7 @@
                        this.CloseForm();
                    });
                }
            })
            { IsBackground = true }.Start();
            });
        }
        #endregion
@@ -511,13 +507,12 @@
            //停止接收
            GatewayResourse.NowSelectGateway.GwResDataAction -= this.AdjustGatewayResultData;
            new System.Threading.Thread(() =>
            HdlThreadLogic.Current.RunThread(() =>
            {
                System.Threading.Thread.Sleep(1200);
                //关闭入网模式
                GatewayResourse.NowSelectGateway.AddNewDeviceToGateway(0);
            })
            { IsBackground = true }.Start();
            });
        }
        #endregion