.vs/HDL_APP_Project/xs/UserPrefs.xml
@@ -1,52 +1,56 @@ <Properties StartupConfiguration="{D998E133-F0DD-4760-BE3C-461632F54DA4}|Default"> <MonoDevelop.Ide.ItemProperties.HDL-ON__iOS PreferredExecutionTarget="MonoDevelop.IPhone.IPhoneDeviceTarget.00008020-000404163432002E" /> <MonoDevelop.Ide.Workbench ActiveDocument="HDL_ON/DAL/Server/HttpServerRequest.cs"> <MonoDevelop.Ide.Workbench ActiveDocument="HDL_ON/UI/UI2/FuntionControlView/1ContorlPage/AcControlPage.cs"> <Files> <File FileName="HDL_ON/Common/ApiUtlis.cs" Line="186" Column="1" /> <File FileName="HDL_ON/Entity/FunctionList.cs" Line="159" Column="38" /> <File FileName="HDL_ON/Entity/Function/Function.cs" Line="927" Column="30" /> <File FileName="HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/AddButton.cs" Line="176" Column="51" /> <File FileName="HDL_ON/UI/UI2/FuntionControlView/1ContorlPage/AcControlPage.cs" Line="494" Column="58" /> <File FileName="HDL-ON_iOS/Info.plist" /> <File FileName="HDL_ON/UI/UI1-Login/LoginPage.cs" Line="15" Column="36" /> <File FileName="HDL_ON/UI/UI1-Login/LoginPageBLL.cs" Line="817" Column="47" /> <File FileName="HDL_ON/DAL/Server/HttpServerRequest.cs" Line="495" Column="30" /> <File FileName="HDL_ON/Entity/ResponseEntity/RegionInfoRes.cs" Line="125" Column="22" /> <File FileName="HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/View/BrandListView.cs" Line="1" Column="1" /> <File FileName="HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/BrandList.cs" Line="62" Column="30" /> <File FileName="HDL_ON/UI/UI2/2-Classification/FunctionControlZone.cs" Line="327" Column="74" /> <File FileName="HDL_ON/UI/UI2/2-Classification/FunctionControlZoneBLL.cs" Line="137" Column="36" /> <File FileName="HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirSend.cs" Line="169" Column="18" /> <File FileName="HDL_ON/Entity/Function/Scene.cs" Line="63" Column="33" /> <File FileName="HDL_ON/UI/UI1-Login/LoginPage.cs" Line="203" Column="24" /> <File FileName="HDL_ON/UI/MainPage.cs" Line="213" Column="32" /> </Files> <Pads> <Pad Id="ProjectPad"> <State name="__root__"> <Node name="HDL_APP_Project" expanded="True"> <Node name="HDL_ON" expanded="True"> <Node name="Common" expanded="True" /> <Node name="DAL" expanded="True"> <Node name="Server" expanded="True"> <Node name="HttpServerRequest.cs" selected="True" /> </Node> </Node> <Node name="Entity" expanded="True"> <Node name="ResponseEntity" expanded="True" /> <Node name="Device" expanded="True" /> <Node name="Function" expanded="True" /> </Node> <Node name="UI" expanded="True"> <Node name="UI0-Public" expanded="True" /> <Node name="UI1-Login" expanded="True" /> <Node name="UI2" expanded="True"> <Node name="3-Intelligence" expanded="True" /> <Node name="4-PersonalCenter" expanded="True"> <Node name="PirDevice" expanded="True" /> </Node> <Node name="FuntionControlView" expanded="True"> <Node name="1ContorlPage" expanded="True"> <Node name="AcControlPage.cs" selected="True" /> </Node> <Node name="Electrical" expanded="True" /> </Node> </Node> </Node> </Node> <Node name="HDL-ON_iOS" expanded="True"> <Node name="Resources" expanded="True"> <Node name="Phone" expanded="True"> <Node name="FunctionIcon" expanded="True"> <Node name="Icon" expanded="True" /> <Node name="Public" expanded="True"> <Node name="MsgIcon" expanded="True" /> </Node> </Node> </Node> </Node> <Node name="ys" expanded="True" /> </Node> </State> </Pad> <Pad Id="MonoDevelop.Debugger.WatchPad"> <State> <Value>tempFunction.name</Value> <Value>filePath</Value> <Value>newFunction.savePath</Value> </State> </Pad> </Pads> HDL-ON_Android/Assets/Phone/Public/MsgIcon/TipIconBlack.pngHDL-ON_Android/Assets/Phone/Public/MsgIcon/TipIconWhite.pngHDL-ON_Android/HDL-ON_Android.csproj
@@ -966,6 +966,7 @@ <AndroidAsset Include="Assets\Phone\FunctionIcon\EnvirSensor\Pm25Bg.png" /> <AndroidAsset Include="Assets\Phone\FunctionIcon\EnvirSensor\0.png" /> <AndroidAsset Include="Assets\Phone\PirIcon\add.png" /> <AndroidAsset Include="Assets\Phone\FunctionIcon\AC\More.png" /> </ItemGroup> <ItemGroup> <AndroidNativeLibrary Include="libs\armeabi-v7a\libelianjni.so" /> HDL-ON_Android/Properties/AndroidManifest.xml
@@ -1,5 +1,5 @@ <?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="202103232" android:versionName="1.1.202103232" package="com.hdl.onpro"> <manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="20210323" android:versionName="1.1.202103233" package="com.hdl.onpro"> <uses-sdk android:minSdkVersion="26" android:targetSdkVersion="26" /> <!-- 定位权限--> <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" /> HDL-ON_Android/Resources/Resource.designer.cs
Diff too large HDL-ON_iOS/HDL-ON_iOS.csproj
@@ -1193,6 +1193,7 @@ <BundleResource Include="Resources\Phone\FunctionIcon\EnvirSensor\TempIcon.png" /> <BundleResource Include="Resources\Phone\FunctionIcon\EnvirSensor\TvocIcon.png" /> <BundleResource Include="Resources\Phone\PirIcon\add.png" /> <BundleResource Include="Resources\Phone\FunctionIcon\AC\More.png" /> </ItemGroup> <ItemGroup> <ITunesArtwork Include="iTunesArtwork" /> HDL-ON_iOS/Info.plist
@@ -104,9 +104,9 @@ <key>UIStatusBarStyle</key> <string>UIStatusBarStyleLightContent</string> <key>CFBundleShortVersionString</key> <string>1.1.202103232</string> <string>1.1.202103233</string> <key>CFBundleVersion</key> <string>202103232</string> <string>202103233</string> <key>NSLocationWhenInUseUsageDescription</key> <string>Use geographic location to provide services such as weather</string> <key>NSAppleMusicUsageDescription</key> HDL-ON_iOS/Resources/Phone/Public/MsgIcon/TipIconBlack.pngHDL-ON_iOS/Resources/Phone/Public/MsgIcon/TipIconWhite.pngHDL-ON_iOS/Resources/Phone/Public/PlusSignIcon.pngHDL_ON/DAL/DriverLayer/Control_Udp.cs
@@ -463,11 +463,11 @@ byte lightBri = Convert.ToByte(function.GetAttrState(FunctionAttributeKey.Brightness)); if (lightBri == 0) { b = 100; b1 = 100; } else { b = lightBri; b1 = lightBri; } } ControlBytesSend(Command.SetSingleLight, subnetId, deviceId, new byte[] { HDL_ON/Entity/Room.cs
@@ -462,10 +462,10 @@ } } /// <summary> /// 房间功能列表 /// </summary> List<Function> functions = new List<Function>(); ///// <summary> ///// 房间功能列表 ///// </summary> //List<Function> functions = new List<Function>(); /// <summary> /// 获取房间功能列表 /// </summary> @@ -473,8 +473,8 @@ { if (needRefresh) { functions = new List<Function>(); } var functions = new List<Function>(); if (functions.Count == 0) { foreach (var f in FunctionList.List.GetDeviceFunctionList()) @@ -487,22 +487,22 @@ } return functions; } /// <summary> /// 增加房间功能 /// 操作的是缓存数据,不用保存 /// </summary> public void AddRoomFunction(Function function) { functions.Add(function); } /// <summary> /// 删除房间功能 /// 操作的是缓存数据,不用保存 /// </summary> public void RemoveRoomFunction(Function function) { functions.Remove(functions.Find((obj) => obj.sid == function.sid)); } ///// <summary> ///// 增加房间功能 ///// 操作的是缓存数据,不用保存 ///// </summary> //public void AddRoomFunction(Function function) //{ // functions.Add(function); //} ///// <summary> ///// 删除房间功能 ///// 操作的是缓存数据,不用保存 ///// </summary> //public void RemoveRoomFunction(Function function) //{ // functions.Remove(functions.Find((obj) => obj.sid == function.sid)); //} /// <summary> /// 房间场景列表 /// </summary> HDL_ON/HDL_ON.projitems
@@ -387,6 +387,7 @@ <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\FuntionControlView\EnvironmentalScience\EnvironmentalPage.cs" /> <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\FuntionControlView\EnvironmentalScience\EchartsOption_Pie.cs" /> <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\4-PersonalCenter\PirDevice\SetPir.cs" /> <Compile Include="$(MSBuildThisFileDirectory)UI\UI2\FuntionControlView\1ContorlPage\AcControlPage_AddIrButton.cs" /> </ItemGroup> <ItemGroup> <Folder Include="$(MSBuildThisFileDirectory)DAL\" /> HDL_ON/UI/MainPage.cs
@@ -18,12 +18,6 @@ /// </summary> public static PageLayout BasePageView { get; set; } /// <summary> /// DisplayCompleted /// </summary> public static bool DisplayCompleted = false; //public static UserInfo LoginUser; /// <summary> /// 版本号 /// </summary> public static string VersionString = "1.1.0323"; @@ -40,6 +34,10 @@ /// 天气刷新action /// </summary> public static Action RefreshAir; /// <summary> /// 回退页面action 没有需要可以不用 /// </summary> public static Action ReturnRefreshAction; /// <summary> /// 无登录模式 /// </summary> @@ -198,13 +196,21 @@ { if (e < BasePageView.ChildrenCount - 1) { MainPage.BasePageView.GetChildren(MainPage.BasePageView.ChildrenCount - 1).RemoveFromParent(); } while (e < BasePageView.ChildrenCount - 1) { BasePageView.GetChildren(BasePageView.ChildrenCount - 1).RemoveFromParent(); } try { ReturnRefreshAction?.Invoke(); ReturnRefreshAction = null; } catch (Exception ex) { Log($"后退事件异常:{ex.Message}"); } //while (e < BasePageView.ChildrenCount - 1) //{ // BasePageView.GetChildren(BasePageView.ChildrenCount - 1).RemoveFromParent(); //} }; BasePageView.MouseDownEventHandler += (sender, e) => { HDL_ON/UI/UI2/2-Classification/FunctionControlZone.cs
@@ -132,7 +132,6 @@ switch (function.Spk_Prefix) { case FunctionCategory.Curtain: CurtainFragment(); break; case FunctionCategory.Sensor: @@ -332,7 +331,7 @@ ProgressTextColor = CSS_Color.FirstLevelTitleColor, ProgressTextSize = CSS_FontSize.PromptFontSize_SecondaryLevel, MaxValue = 100, Progress = Convert.ToInt32(function.GetAttrState(FunctionAttributeKey.BatteryState)), Progress = Convert.ToInt32(function.GetAttrState(FunctionAttributeKey.Brightness)), Tag = function.sid + "_DimmerBar", SeekBarPadding = Application.GetRealWidth(20), }; HDL_ON/UI/UI2/2-Classification/FunctionControlZoneBLL.cs
@@ -76,13 +76,25 @@ /// </summary> void LoadEvent_SwitchFunction(Button btnSwitch,FunctionAttributes fadeTime = null) { btnSwitch.MouseUpEventHandler = (sender, e) => { btnSwitch.IsSelected = !btnSwitch.IsSelected; if(function.spk == SPK.IrLearn || function.spk == SPK.TvIr) { new System.Threading.Thread(() => { System.Threading.Thread.Sleep(2000); Application.RunOnMainThread(() => { btnSwitch.IsSelected = !btnSwitch.IsSelected; }); }) { IsBackground = true }.Start(); } new System.Threading.Thread(() => { function.trait_on_off.curValue = btnSwitch.IsSelected ? "on" : "off"; System.Collections.Generic.Dictionary<string, string> d = new System.Collections.Generic.Dictionary<string, string>(); Dictionary<string, string> d = new Dictionary<string, string>(); d.Add(FunctionAttributeKey.OnOff, function.trait_on_off.curValue.ToString()); if(fadeTime!= null) { HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/AddButton.cs
@@ -132,7 +132,7 @@ buttonObj.key = "key" + control.status.Count.ToString(); buttonObj.value = texts; PirSend.CodeStudy(control, buttonObj, (responsePackNew) => PirSend.CodeStudy(control.deviceId, buttonObj, (responsePackNew) => { if (responsePackNew != null && responsePackNew.Code == "0" && responsePackNew.Data.ToString() != "") { HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/BrandList.cs
@@ -58,7 +58,7 @@ var library = Newtonsoft.Json.JsonConvert.DeserializeObject<Library>(str); if (library != null) { if (libraryList.Count < 20) if (libraryList.Count < 40) { libraryList.Add(library); } HDL_ON/UI/UI2/4-PersonalCenter/PirDevice/PirSend.cs
@@ -150,7 +150,7 @@ /// 红外码学习 /// </summary> /// <returns></returns> public static void CodeStudy(Control control,AttributesStatus buttonObj,Action<ResponsePackNew> action) public static void CodeStudy(string deviceId,AttributesStatus buttonObj,Action<ResponsePackNew> action) { var job = new JObject { }; job.Add("key", buttonObj.key); @@ -160,7 +160,7 @@ job.Add("value", valuejArray); var jArray = new JArray { }; jArray.Add(job); var jObject = new JObject { { "homeId", HomeId }, { "deviceId", control.deviceId }, { "attributes", jArray } }; var jObject = new JObject { { "homeId", HomeId }, { "deviceId", deviceId }, { "attributes", jArray } }; ResponsePackNew responsePackNew = null; new System.Threading.Thread(() => { HDL_ON/UI/UI2/FuntionControlView/1ContorlPage/AcControlPage.cs
@@ -1,4 +1,5 @@ using System; using System.Collections.Generic; using HDL_ON.DriverLayer; using HDL_ON.Entity; using HDL_ON.Stan; @@ -408,9 +409,9 @@ TextSize = CSS_FontSize.TextFontSize, }; modeChangeView.AddChidren(btnFanText); btnFanIcon.UnSelectedImagePath = acFunction.GetModeIconPath(m,false); btnFanIcon.SelectedImagePath = acFunction.GetModeIconPath(m); btnFanText.Text = acFunction.GetModeAttrText(m); btnFanIcon.UnSelectedImagePath = acFunction.GetFanIconPath(m,false); btnFanIcon.SelectedImagePath = acFunction.GetFanIconPath(m); btnFanText.Text = acFunction.GetFanAttrText(m); if (modeList.IndexOf(m) < modeList.Count - 1) { @@ -490,13 +491,14 @@ }; div.AddChidren(bodyView); var contentView = new FrameLayout() var contentView = new VerticalScrolViewLayout() { Y = Application.GetRealHeight(16), Gravity = Gravity.CenterHorizontal, Width = Application.GetRealWidth(296), }; bodyView.AddChidren(contentView); var row = new FrameLayout() { @@ -505,7 +507,14 @@ contentView.AddChidren(row); int index = 0; foreach (var attr in device.attributes) List<FunctionAttributes> attrList = new List<FunctionAttributes>(); attrList.AddRange(device.attributes); attrList.Add(new FunctionAttributes() { key = "+", }); foreach (var attr in attrList) { if (attr.key == FunctionAttributeKey.Mode || attr.key == FunctionAttributeKey.OnOff @@ -522,13 +531,57 @@ { row = new FrameLayout() { Width = Application.GetRealWidth(200), Height = Application.GetRealHeight(56), }; contentView.AddChidren(row); } if (attr.key == "+") { var addView = new FrameLayout() { Gravity = Gravity.CenterVertical, Width = Application.GetRealWidth(88), Height = Application.GetRealHeight(40), Radius = (uint)Application.GetRealHeight(18), BorderColor = CSS_Color.PromptingColor1, BorderWidth = (uint)Application.GetRealWidth(2), }; var btn = new Button() if (index % 3 == 1) { addView.Gravity = Gravity.Center; } else if (index % 3 == 2) { addView.X = Application.GetRealWidth(208); } row.AddChidren(addView); var btnAdd = new Button() { Gravity = Gravity.Center, UnSelectedImagePath = "Public/PlusSignIcon.png", Width = Application.GetRealWidth(32), Height = Application.GetRealWidth(32), }; addView.AddChidren(btnAdd); btnAdd.MouseUpEventHandler = (sender, e) => { dialog.Close(); var addButton = new AcControlPage_AddIrButton(); MainPage.BasePageView.AddChidren(addButton); addButton.Show(device); MainPage.BasePageView.PageIndex = MainPage.BasePageView.ChildrenCount - 1; }; } else { var btn = new Button() { Gravity = Gravity.CenterVertical, Width = Application.GetRealWidth(88), @@ -573,7 +626,7 @@ { IsBackground = true }.Start(); }; } index++; } HDL_ON/UI/UI2/FuntionControlView/1ContorlPage/AcControlPage_AddIrButton.cs
New file @@ -0,0 +1,167 @@ using System; using HDL_ON.Entity; using HDL_ON.UI.UI2.Intelligence.Automation.LogicView; using HDL_ON.UI.UI2.PersonalCenter.PirDevice; using HDL_ON.UI.UI2.PersonalCenter.PirDevice.View; using Shared; namespace HDL_ON.UI { public class AcControlPage_AddIrButton : FrameLayout { public AcControlPage_AddIrButton() { } public void Show(Function control) { #region 界面布局 this.BackgroundColor = CSS.CSS_Color.viewMiddle; UI2.PersonalCenter.PirDevice.View.TopView topView = new UI2.PersonalCenter.PirDevice.View.TopView(); topView.topNameBtn.TextID = StringId.tianjiayaokongqi; this.AddChidren(topView.FLayoutView()); topView.clickBackBtn.MouseUpEventHandler += (sender, e) => { this.RemoveFromParent(); }; FrameLayout editfLayout = new FrameLayout { Y = topView.frameLayout.Bottom, BackgroundColor = CSS.CSS_Color.textWhiteColor, Height = Application.GetRealHeight(152), Width = Application.GetRealWidth(375), }; this.AddChidren(editfLayout); //线 Button lineBtn = new Button { Y = Application.GetRealHeight(43), X = Application.GetRealWidth(16), Width = Application.GetRealWidth(375 - 16 * 2), Height = 1, BackgroundColor = CSS.CSS_Color.viewLine, }; editfLayout.AddChidren(lineBtn); //请输入按键名称 EditText editText = new EditText() { X = Application.GetRealWidth(16), Width = Application.GetRealWidth(375 - 16 * 2), Height = Application.GetRealHeight(44), PlaceholderText = Language.StringByID(StringId.anjianmingcheng), PlaceholderTextColor = CSS.CSS_Color.textCancelColor, TextColor = CSS.CSS_Color.textColor, TextSize = TextSize.text14, TextAlignment = TextAlignment.CenterLeft, }; editfLayout.AddChidren(editText); //下一步 Button saveBtn = new Button { Width = Application.GetRealWidth(220), Height = Application.GetRealHeight(44), Y = Application.GetRealHeight(92), X = Application.GetRealWidth(78), TextID = StringId.xiayibu, TextSize = TextSize.text16, TextColor = CSS.CSS_Color.textWhiteColor, TextAlignment = TextAlignment.Center, BackgroundColor = CSS.CSS_Color.btnSaveBackgroundColor, Radius = (uint)Application.GetRealHeight(22), }; editfLayout.AddChidren(saveBtn); FrameLayout fLayout = new FrameLayout { Y = editfLayout.Bottom + Application.GetRealHeight(8), Height = Application.GetRealHeight(667 - 64 - 152 - 8), Width = Application.GetRealWidth(375), BackgroundColor = CSS.CSS_Color.textWhiteColor, }; this.AddChidren(fLayout); //推荐按键 Button titleBtn = new Button { Y = Application.GetRealHeight(12), X = Application.GetRealWidth(16), Width = Application.GetRealWidth(220), Height = Application.GetRealHeight(20), TextID = StringId.tuijiananjian, TextSize = TextSize.text14, TextColor = CSS.CSS_Color.text1Color, TextAlignment = TextAlignment.CenterLeft, }; fLayout.AddChidren(titleBtn); //动态加载Button按钮父控件 FrameLayout buttonFLayout = new FrameLayout { Y = Application.GetRealHeight(32), Height = Application.GetRealHeight(667 - 64 - 152 - 8 - 12 - 20), Width = Application.GetRealWidth(375), }; fLayout.AddChidren(buttonFLayout); #endregion Buttons buttons = new Buttons(); var buttonNameList = buttons.GetList("默认按钮"); buttons.AddButton(buttonFLayout, buttonNameList, (s) => { editText.Text = s; #if __Android__ editText.SetSelectionEnd(); #endif }); ///下一步的点击事件 saveBtn.MouseUpEventHandler += (sender, e) => { var texts = editText.Text.Trim(); if (string.IsNullOrEmpty(editText.Text)) { //名称不能为空 return; } var butName = control.attributes.Find((c) => c.key == texts); if (butName != null) { //名称已经存在 return; } //new引导界面 ReplicationView replication = new ReplicationView(); replication.Show(this); //添加数据对象 AttributesStatus buttonObj = new AttributesStatus(); buttonObj.key = "key" + control.attributes.Count.ToString(); buttonObj.value = texts; PirSend.CodeStudy(control.deviceId, buttonObj, (responsePackNew) => { if (responsePackNew != null && responsePackNew.Code == "0" && responsePackNew.Data.ToString() != "") { Method method = new Method(); Method.buttondata = ""; var mqttdate = method.MqttDate("按键", control.sid, 25); if (mqttdate != null) { this.RemoveFromParent(); control.attributes.Add(new FunctionAttributes() { key = buttonObj.key, value = new System.Collections.Generic.List<string>() { buttonObj.value } }); } else { replication.RemView(); new TipPopView().FlashingBox(Language.StringByID(StringId.tianjiashibai)); } } else { Method method = new Method(); method.ErrorShow(responsePackNew, ""); } }); }; } } } HDL_ON/UI/UI2/FuntionControlView/ChooseRoomPageBLL.cs
@@ -72,12 +72,12 @@ if (isAdd) { function.roomIds.Add(room.roomId); room.AddRoomFunction(function); //room.AddRoomFunction(function); } else { function.roomIds.Remove(room.roomId); room.RemoveRoomFunction(function); //room.RemoveRoomFunction(function); } function.UpdataRoomIds(); if (function.roomIds.Count == Entity.SpatialInfo.CurrentSpatial.RoomList.Count) HDL_ON/UI/UI2/FuntionControlView/Electrical/IrLearnPage.cs
@@ -45,7 +45,6 @@ var row = new FrameLayout() { //Width = Application.GetRealWidth(200), Height = Application.GetRealHeight(56), }; contentView.AddChidren(row); @@ -53,11 +52,10 @@ int index = 0; foreach(var attr in device.attributes) { if(index != 0 && index%3==0) if (index != 0 && index % 3 == 0) { row = new FrameLayout() { Width = Application.GetRealWidth(200), Height = Application.GetRealHeight(56), }; contentView.AddChidren(row); HDL_ON/UI/UI2/FuntionControlView/Light/DimmerPageBLL.cs
@@ -91,10 +91,10 @@ dimmerBar.OnStopTrackingTouchEvent = (sender, e) => { onDimmerBar = false; function.SetAttrState(FunctionAttributeKey.Brightness, dimmerBar.Progress); function.SetAttrState(FunctionAttributeKey.FadeTime, barFadeTime.Progress); System.Collections.Generic.Dictionary<string, string> d = new System.Collections.Generic.Dictionary<string, string>(); d.Add(FunctionAttributeKey.Brightness, dimmerBar.Progress.ToString()); Control.Ins.SendWriteCommand(function, d); function.SetAttrState(FunctionAttributeKey.FadeTime, barFadeTime.Progress); btnBrightnessText.Text = dimmerBar.Progress + "%"; }; //20201223 删除滑动发送命令,防止控件跳动