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/1-HomePage/HomePage.cs | 17 +++++++++++++----
1 files changed, 13 insertions(+), 4 deletions(-)
diff --git a/HDL_ON/UI/UI2/1-HomePage/HomePage.cs b/HDL_ON/UI/UI2/1-HomePage/HomePage.cs
index 631866a..8835c07 100644
--- a/HDL_ON/UI/UI2/1-HomePage/HomePage.cs
+++ b/HDL_ON/UI/UI2/1-HomePage/HomePage.cs
@@ -724,7 +724,8 @@
try
{
int index = 0;
- var list = FunctionList.List.GetDeviceFunctionList();
+ var list = new List<Function>();
+ list.AddRange(FunctionList.List.GetDeviceFunctionList());
list.AddRange(FunctionList.List.groupControls);//鍔犲叆缇ゆ帶
foreach (var function in list)
{
@@ -1024,6 +1025,7 @@
btnState.Text = function.lastState;
}
}
+
else
{
btnIcon.UnSelectedImagePath = $"FunctionIcon/Icon/HomeIcon/{function.IconName}_blue.png";
@@ -1221,9 +1223,16 @@
SelectedImagePath = "Public/SwitchOn.png",
};
view.AddChidren(btnSwitch);
-
- btnIcon.UnSelectedImagePath = $"FunctionIcon/Icon/HomeIcon/{function.IconName}_blue.png";
- btnIcon.SelectedImagePath = $"FunctionIcon/Icon/HomeIcon/{function.IconName}_white.png";
+ if (function.spk == SPK.GroupControl)
+ {
+ btnIcon.UnSelectedImagePath = $"FunctionIcon/Icon/HomeIcon/lightswitch_blue.png";
+ btnIcon.SelectedImagePath = $"FunctionIcon/Icon/HomeIcon/lightswitch_white.png";
+ }
+ else
+ {
+ btnIcon.UnSelectedImagePath = $"FunctionIcon/Icon/HomeIcon/{function.IconName}_blue.png";
+ btnIcon.SelectedImagePath = $"FunctionIcon/Icon/HomeIcon/{function.IconName}_white.png";
+ }
LoadEvent_SwitchFunction(function, btnSwitch);
}
//鍙栨秷鏀惰棌浜嬩欢
--
Gitblit v1.8.0