删除DeviceManager和V8类中未使用的字段,消除CS0414警告
This commit is contained in:
@@ -191,7 +191,7 @@ namespace JoyD.Windows.CS.Toprie
|
|||||||
// 重连间隔(毫秒)
|
// 重连间隔(毫秒)
|
||||||
private int _reconnectInterval = 2000;
|
private int _reconnectInterval = 2000;
|
||||||
// 重连尝试次数
|
// 重连尝试次数
|
||||||
private int _reconnectAttempts = 0;
|
|
||||||
// 最大重连尝试次数
|
// 最大重连尝试次数
|
||||||
public static int MaxReconnectAttempts = 5;
|
public static int MaxReconnectAttempts = 5;
|
||||||
// 连接检查定时器
|
// 连接检查定时器
|
||||||
@@ -3188,7 +3188,6 @@ namespace JoyD.Windows.CS.Toprie
|
|||||||
if (result)
|
if (result)
|
||||||
{
|
{
|
||||||
_isConnected = true;
|
_isConnected = true;
|
||||||
_reconnectAttempts = 0;
|
|
||||||
|
|
||||||
// 启动心跳检测和连接检查
|
// 启动心跳检测和连接检查
|
||||||
StartHeartbeat();
|
StartHeartbeat();
|
||||||
|
|||||||
@@ -129,8 +129,7 @@ namespace JoyD.Windows.CS.Toprie
|
|||||||
|
|
||||||
// 私有字段
|
// 私有字段
|
||||||
private string deviceIp;
|
private string deviceIp;
|
||||||
private Socket socket;
|
private Socket socket = null;
|
||||||
private bool isConnected = false;
|
|
||||||
private static bool isSdkInitialized = false;
|
private static bool isSdkInitialized = false;
|
||||||
private static Dictionary<string, V8> deviceInstances = new Dictionary<string, V8>();
|
private static Dictionary<string, V8> deviceInstances = new Dictionary<string, V8>();
|
||||||
|
|
||||||
@@ -159,7 +158,6 @@ namespace JoyD.Windows.CS.Toprie
|
|||||||
socket.Close();
|
socket.Close();
|
||||||
socket = null;
|
socket = null;
|
||||||
}
|
}
|
||||||
isConnected = false;
|
|
||||||
Console.WriteLine("UDP通信状态已重置");
|
Console.WriteLine("UDP通信状态已重置");
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
|
|||||||
Reference in New Issue
Block a user