From b586d247109d5bdb410c473ab161aff005e1bd70 Mon Sep 17 00:00:00 2001
From: lss <lsc@hdlchina.com.cn>
Date: 星期一, 13 六月 2022 19:37:31 +0800
Subject: [PATCH] 1
---
HDL_ON/UI/UI2/1-HomePage/HomePageBLL.cs | 46 ++++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 46 insertions(+), 0 deletions(-)
diff --git a/HDL_ON/UI/UI2/1-HomePage/HomePageBLL.cs b/HDL_ON/UI/UI2/1-HomePage/HomePageBLL.cs
index 0bbd7a4..342d1d5 100644
--- a/HDL_ON/UI/UI2/1-HomePage/HomePageBLL.cs
+++ b/HDL_ON/UI/UI2/1-HomePage/HomePageBLL.cs
@@ -10,6 +10,52 @@
public partial class HomePage
{
/// <summary>
+ /// 鏇存柊璁惧鍦ㄧ嚎鐘舵��
+ /// </summary>
+ public static void LoadEvent_RefreshDevcieOnline(Function function)
+ {
+ Application.RunOnMainThread(() =>
+ {
+ if (bodyView != null)
+ {
+ foreach (var view in bodyView.functionViews)
+ {
+ if (view.Tag.ToString() == function.sid)
+ {
+ for (int i = 0; i < view.ChildrenCount; i++)
+ {
+ if (view.GetChildren(i).GetType() == typeof(Button))
+ {
+ var btn = view.GetChildren(i) as Button;
+ if(btn.Tag == null)
+ {
+ continue;
+ }
+ if (btn.Tag.ToString() == function.sid)
+ {
+ if (function.online)
+ {
+ btn.UnSelectedImagePath = "Collection/Functionbg.png";
+ btn.IsSelected = false;
+ }
+ else
+ {
+ btn.UnSelectedImagePath = "Collection/FunctionOfflineBg.png";
+ btn.IsSelected = false;
+ }
+ }
+ else if (btn.Tag.ToString() == "OnlineTag")
+ {
+ btn.Visible = !function.online;
+ }
+ }
+ }
+ }
+ }
+ }
+ });
+ }
+ /// <summary>
/// 鏇存柊涓婚〉澶╂皵
/// </summary>
public static void LoadEvent_RefreshAir()
--
Gitblit v1.8.0