From ea285ffe71284f5499e870f89c65b710d2d6a79c Mon Sep 17 00:00:00 2001 From: lss <lsc@hdlchina.com.cn> Date: 星期一, 27 六月 2022 10:54:32 +0800 Subject: [PATCH] Merge branch 'wxr0114' of http://59.41.255.150:6688/r/~wxr/OnPro into wxr0114 --- HDL_ON/UI/UI2/FuntionControlView/Light/DimmerPageBLL.cs | 23 +++++++++++------------ 1 files changed, 11 insertions(+), 12 deletions(-) diff --git a/HDL_ON/UI/UI2/FuntionControlView/Light/DimmerPageBLL.cs b/HDL_ON/UI/UI2/FuntionControlView/Light/DimmerPageBLL.cs index 519aec2..55bc4b3 100644 --- a/HDL_ON/UI/UI2/FuntionControlView/Light/DimmerPageBLL.cs +++ b/HDL_ON/UI/UI2/FuntionControlView/Light/DimmerPageBLL.cs @@ -90,7 +90,7 @@ /// </summary> void LoadEvent_DimmerBar() { - //if (function.online) + if (function.online) { dimmerBar.OnStartTrackingTouchEvent = (sender, e) => { @@ -155,16 +155,16 @@ { btnSwitch.MouseUpEventHandler += (sender, e) => { - //if (!function.online) - //{ - // new Tip() - // { - // CloseTime = 1, - // Text = Language.StringByID(StringId.DeviceOfflineCannotOption), - // Direction = AMPopTipDirection.None, - // }.Show(MainPage.BaseView); - // return; - //} + if (!function.online) + { + new Tip() + { + CloseTime = 1, + Text = Language.StringByID(StringId.DeviceOfflineCannotOption), + Direction = AMPopTipDirection.None, + }.Show(MainPage.BaseView); + return; + } btnSwitch.IsSelected = !btnSwitch.IsSelected; if (btnSwitch.IsSelected) { @@ -179,7 +179,6 @@ function.trait_on_off.curValue = btnSwitch.IsSelected ? "on" : "off"; System.Collections.Generic.Dictionary<string, string> d = new System.Collections.Generic.Dictionary<string, string>(); d.Add(FunctionAttributeKey.OnOff, function.trait_on_off.curValue.ToString()); - d.Add(FunctionAttributeKey.FadeTime, function.GetAttrState(FunctionAttributeKey.FadeTime)); if (btnSwitch.IsSelected) { if(function.lastBrightness == 0) -- Gitblit v1.8.0