From 452e8cef1c740d18ee398be6971d9952e41dbd4a Mon Sep 17 00:00:00 2001
From: wxr <464027401@qq.com>
Date: 星期三, 12 四月 2023 16:11:50 +0800
Subject: [PATCH] 1
---
HDL_ON/UI/UI2/FuntionControlView/FunctionBaseInfoSetPageBLL.cs | 42 ++++++++++++++++++++++++++++++++++++++++++
1 files changed, 42 insertions(+), 0 deletions(-)
diff --git a/HDL_ON/UI/UI2/FuntionControlView/FunctionBaseInfoSetPageBLL.cs b/HDL_ON/UI/UI2/FuntionControlView/FunctionBaseInfoSetPageBLL.cs
index 006e71d..ff4c689 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/FunctionBaseInfoSetPageBLL.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/FunctionBaseInfoSetPageBLL.cs
@@ -12,6 +12,8 @@
{
LoadEvent_ChangeFunctionName ();
SkipChooseRoomPage();
+ DelDeviceEvent();
+
}
/// <summary>
@@ -77,5 +79,45 @@
}
}
+ /// <summary>
+ /// 瑙g粦璁惧鐨勪簨浠�
+ /// </summary>
+ void DelDeviceEvent()
+ {
+
+ EventHandler<MouseEventArgs> ClickEvent = (sener, e) =>
+ {
+ new HDL_ON.UI.Music.View.TipView().TipBox(-1, StringId.AreYouSureToDeleteThisDevice, () =>
+ {
+ UI2.FuntionControlView.VideoDoorLock.VideDoorLockSend.Current.DelDevice(this.function, (isBool) =>
+ {
+ Application.RunOnMainThread(() =>
+ {
+ if (!isBool)
+ {
+ new Tip()
+ {
+ CloseTime = 1,
+ Text = Language.StringByID(StringId.delFail),
+ Direction = AMPopTipDirection.None,
+ }.Show(bodyView);
+ return;
+ }
+ //鍒犻櫎鏈湴鏂囦欢
+ UI2.FuntionControlView.VideoDoorLock.CommonMethod.Current.DeleteFunction(this.function);
+ this.RemoveFromParent();
+ this.actionDel?.Invoke();
+ });
+
+ });
+
+ });
+ };
+ this.delView.MouseUpEventHandler += ClickEvent;
+ this.delTextBtn.MouseUpEventHandler += ClickEvent;
+ this.delRightBtn.MouseUpEventHandler += ClickEvent;
+ }
+
+
}
}
--
Gitblit v1.8.0