From 4f2dbd1f6a1ec2d9c3c39b4a37b0b7c9ddece4aa Mon Sep 17 00:00:00 2001 From: wei <kaede@kaededeMacBook-Air.local> Date: 星期四, 23 九月 2021 15:24:01 +0800 Subject: [PATCH] 主页刷新优化 --- HDL_ON/UI/UI2/1-HomePage/HomePageBLL.cs | 13 +++++++++---- 1 files changed, 9 insertions(+), 4 deletions(-) diff --git a/HDL_ON/UI/UI2/1-HomePage/HomePageBLL.cs b/HDL_ON/UI/UI2/1-HomePage/HomePageBLL.cs index 013396b..75cec12 100644 --- a/HDL_ON/UI/UI2/1-HomePage/HomePageBLL.cs +++ b/HDL_ON/UI/UI2/1-HomePage/HomePageBLL.cs @@ -266,7 +266,6 @@ btnChangeScene.IsBold = false; CurShowTypeIsFunction = true; contentView.PageIndex = 0; - }; //var client = new BlufiClient(); @@ -298,7 +297,6 @@ btnChangeScene.TextSize = CSS.CSS_FontSize.TextFontSize; btnChangeScene.IsSelected = false; btnChangeScene.IsBold = false; - CurShowTypeIsFunction = true; } else { @@ -308,7 +306,6 @@ btnChangeFunction.TextSize = CSS.CSS_FontSize.TextFontSize; btnChangeFunction.IsSelected = false; btnChangeFunction.IsBold = false; - CurShowTypeIsFunction = false; } }; } @@ -332,7 +329,15 @@ if (function.spk == SPK.CurtainRoller || function.spk == SPK.CurtainShades || function.spk == SPK.CurtainTrietex || function.spk == SPK.CurtainSwitch)//绐楀笜璁惧鏍规嵁鐧惧垎姣斿垽鏂紑鍏崇姸鎬� { - state = function.GetAttrState(FunctionAttributeKey.Percent) != "0"; + if (function.GetAttribute(FunctionAttributeKey.Percent) != null) + { + state = function.GetAttrState(FunctionAttributeKey.Percent) != "0"; + }else + { + if (function.GetAttrState(FunctionAttributeKey.OnOff) == "stop") + return; + state = function.trait_on_off.curValue.ToString() == "on"; + } } else { -- Gitblit v1.8.0