From b69d7735274b8d0f741da8a6bb8b8e1347477a5a Mon Sep 17 00:00:00 2001
From: wxr <464027401@qq.com>
Date: 星期四, 19 三月 2020 17:14:16 +0800
Subject: [PATCH] 20200319

---
 HDL_ON/UI/UI2/FuntionControlView/Curtain/CurtainModulePageBLL.cs |   42 +++++++++++++++++++++++++++++++++++++++++-
 1 files changed, 41 insertions(+), 1 deletions(-)

diff --git a/HDL_ON/UI/UI2/FuntionControlView/Curtain/CurtainModulePageBLL.cs b/HDL_ON/UI/UI2/FuntionControlView/Curtain/CurtainModulePageBLL.cs
index 0457ecb..2f4ec1c 100644
--- a/HDL_ON/UI/UI2/FuntionControlView/Curtain/CurtainModulePageBLL.cs
+++ b/HDL_ON/UI/UI2/FuntionControlView/Curtain/CurtainModulePageBLL.cs
@@ -1,16 +1,56 @@
 锘縰sing System;
+using HDL_ON.Entity;
 namespace HDL_ON.UI
 {
     public partial class CurtainModulePage
     {
         void LoadEventList()
         {
-
+            LoadCollectionEvent();
+            LoadEvent_ControlEvent();
             //鍥為��鍒锋柊淇℃伅浜嬩欢
             actionRefresh = () => {
                 btnFunctionName.Text = btnFunctionName_Out.Text = function.name;
                 btnFromFloor_Out.Text = btnFromFoorAndRoom.Text = function.GetRoomListName();
             };
         }
+        /// <summary>
+        /// 鏀惰棌鍔熻兘鎸夐挳浜嬩欢
+        /// </summary>
+        void LoadCollectionEvent()
+        {
+            btnCollection.MouseUpEventHandler += (sender, e) => {
+                btnCollection.IsSelected = function.collection = btnCollection_Out.IsSelected = !btnCollection.IsSelected;
+                DB_ResidenceData.residenceData.SaveResidenceData();
+            };
+        }
+
+        /// <summary>
+        /// 鍔犺浇绐楀笜寮�鍏冲仠鎸夐挳鎺у埗浜嬩欢
+        /// </summary>
+        void LoadEvent_ControlEvent()
+        {
+            btnCurtainClose.MouseDownEventHandler += (sender, e) => {
+                btnCurtainClose.IsSelected = true;
+            };
+            btnCurtainClose.MouseUpEventHandler += (sender, e) => {
+                btnCurtainClose.IsSelected = false;
+            };
+
+            btnCurtainStop.MouseDownEventHandler += (sender, e) => {
+                btnCurtainStop.IsSelected = true;
+            };
+            btnCurtainStop.MouseUpEventHandler += (sender, e) => {
+                btnCurtainStop.IsSelected = false;
+            };
+
+            btnCurtainOpen.MouseDownEventHandler += (sender, e) => {
+                btnCurtainOpen.IsSelected = true;
+            };
+            btnCurtainOpen.MouseUpEventHandler += (sender, e) => {
+                btnCurtainOpen.IsSelected = false;
+            };
+
+        }
     }
 }

--
Gitblit v1.8.0