JLChen
2020-11-25 4e6dfedede622d018b0aec0fb85c130d47cf45ba
HDL-ON_Android/Application.cs
@@ -63,14 +63,13 @@
                BaseActivity.NetworkStateChanged += (int obj) =>
                {
                    if (!IsEnterBackground)
                    {
                        BusSocket.Stop();
                        //BusSocket.Stop();
                        new System.Threading.Thread(() =>
                        {
                            System.Threading.Thread.Sleep(1000);
                            BusSocket.Start(6000);
                            //BusSocket.Start();
                        })
                        { IsBackground = true }.Start();
                    }
@@ -94,7 +93,7 @@
            BaseActivity.OnDestroyAction += (activity) =>
            {
                Console.WriteLine("OnDestroyAction");
                BusSocket.Stop();
                //BusSocket.Stop();
                OnAppConfig.Instance.unlockTime = DateTime.Now;
            };
@@ -116,6 +115,7 @@
        void init()
        {
            //手机名称 Android.OS.Build.Manufacturer;
            OnAppConfig.Instance.PhoneName = Android.OS.Build.Manufacturer;
        }
        void checkSomeInfo()
        {
@@ -241,7 +241,7 @@
        void BusSocketStop()
        {
            IsEnterBackground = true;
            BusSocket.Stop();
            //BusSocket.Stop();
            OnAppConfig.Instance.unlockTime = DateTime.Now;
        }
@@ -253,7 +253,7 @@
        {
            IsEnterBackground = false;
            BusSocket.Start(6000);
            //BusSocket.Start();
        }
    }
}