WJC
2019-11-04 e5f993f52e09eb46878baced83bb8492f147d41c
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,11 +143,11 @@
                    GatewayResourse.NowSelectGateway.AddNewDeviceToGateway(255);
                    System.Threading.Thread.Sleep(1000);
                }
            })
            { IsBackground = true }.Start();
            });
            //添加监视设备新上报的事件
            GatewayResourse.NowSelectGateway.GwResDataAction += this.AdjustGatewayResultData;
            //开启连接的假想动画效果线程
            this.StartConcetionAnimeteThread();
        }
@@ -251,7 +251,7 @@
            }
            this.isDeviceThreadStart = true;
            new System.Threading.Thread(() =>
            HdlThreadLogic.Current.RunThread(() =>
            {
                while (this.waitDeviceTimeOut >= 0)
                {
@@ -279,8 +279,7 @@
                        break;
                    }
                });
            })
            { IsBackground = true }.Start();
            });
        }
        /// <summary>
@@ -331,7 +330,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 +349,7 @@
                        }
                    });
                }
            })
            { IsBackground = true }.Start();
            });
        }
        #endregion
@@ -462,7 +460,7 @@
                //文本显示
                btnProgressView.Text = ((int)(result * 100)) + "%";
                //文本显示的那个图片框移动
                frameProgress.X = ControlCommonResourse.XXLeft + btnProgressBar.Right - frameProgress.Width / 2;
                frameProgress.X = Application.GetRealWidth(262) + btnProgressBar.Right - frameProgress.Width / 2;
            });
        }
@@ -476,7 +474,7 @@
                return;
            }
            this.isTopicTimeOutThreadStart = true;
            new System.Threading.Thread(() =>
            HdlThreadLogic.Current.RunThread(() =>
            {
                while (this.Parent != null && this.topTimeOut >= 0)
                {
@@ -494,8 +492,7 @@
                        this.CloseForm();
                    });
                }
            })
            { IsBackground = true }.Start();
            });
        }
        #endregion
@@ -511,13 +508,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