From 20e0fb92d25047fabd2dc418597c0ff9b595b07c Mon Sep 17 00:00:00 2001
From: JLChen <551775569@qq.com>
Date: 星期一, 21 十二月 2020 19:35:33 +0800
Subject: [PATCH] 2020-12-21 1.解决房间修改图片后,分类页面对应房间图标没及时刷新问题。
---
HDL-ON_Android/Application.cs | 39 +++++++++++++++++++++++++++++++--------
1 files changed, 31 insertions(+), 8 deletions(-)
diff --git a/HDL-ON_Android/Application.cs b/HDL-ON_Android/Application.cs
index 3d80e26..44e4c01 100644
--- a/HDL-ON_Android/Application.cs
+++ b/HDL-ON_Android/Application.cs
@@ -86,7 +86,7 @@
//}
//缃戠粶鍙樺寲澶勭悊
- HDLCommon.Current.UpdateInternetStatus((int)internetStatus, IsEnterBackground);
+ HDLCommon.Current.UpdateInternetStatus((int)internetStatus, MainPage.IsEnterBackground);
};
//寮�鍚畾浣嶆湇鍔�
Shared.Application.StartGPSLocationService();
@@ -309,30 +309,53 @@
int mCount;
+ ///// <summary>
+ ///// 鏄惁杩涘叆鍚庡彴
+ ///// </summary>
+ //public bool IsEnterBackground = false;
+
/// <summary>
- /// 鏄惁杩涘叆鍚庡彴
+ /// 杩涘叆鍚庡彴鐨勬椂闂�
/// </summary>
- public bool IsEnterBackground = false;
+ DateTime CloseTime = DateTime.Now;
/// <summary>
/// BusSocketStop
/// </summary>
void BusSocketStop()
{
- IsEnterBackground = true;
- //BusSocket.Stop();
+ //IsEnterBackground = true;
+ CloseTime = DateTime.Now;
+ MainPage.IsEnterBackground = true;
+ //杩涘叆鍚庡彴mqtt姝e湪杩炴帴閲嶇疆鐘舵��
+ HDL_ON.DAL.Mqtt.MqttClient.RemoteMqttIsConnecting = false;
+ HDL_ON.DriverLayer.UdpSocket._BusSocket.Stop();
+
}
-
/// <summary>
/// BusSocketStart
/// </summary>
void BusSocketStart()
{
- IsEnterBackground = false;
+ //IsEnterBackground = false;
- //BusSocket.Start();
+ if (CloseTime.AddSeconds(10) < DateTime.Now)
+ {
+ //鍚庡彴瓒呰繃10s灏辨柇寮�MQTT閲嶈繛
+ if (HDL_ON.DriverLayer.Control.Ins.IsRemote)
+ {
+ HDL_ON.DAL.Mqtt.MqttClient.DisConnectRemote("closeTime", false);
+ }
+ }
+
+ MainPage.IsEnterBackground = false;
+ HDL_ON.DriverLayer.UdpSocket._BusSocket.Start();
+ HDL_ON.DriverLayer.Control.Ins.SearchLoaclGateway();
}
+
+
+
}
}
\ No newline at end of file
--
Gitblit v1.8.0