From 9c6bd67d66859e48f0e794cd2746aef9310ce71d Mon Sep 17 00:00:00 2001 From: WJC <wjc@hdlchina.com.cn> Date: 星期五, 13 十二月 2019 18:01:37 +0800 Subject: [PATCH] 2019-12-13-2 --- ZigbeeApp/Shared/Phone/Device/Logic/LogicDevicePage.cs | 62 ++++++++++++++++++------------- 1 files changed, 36 insertions(+), 26 deletions(-) diff --git a/ZigbeeApp/Shared/Phone/Device/Logic/LogicDevicePage.cs b/ZigbeeApp/Shared/Phone/Device/Logic/LogicDevicePage.cs index 6f5d2f0..27130ce 100644 --- a/ZigbeeApp/Shared/Phone/Device/Logic/LogicDevicePage.cs +++ b/ZigbeeApp/Shared/Phone/Device/Logic/LogicDevicePage.cs @@ -1054,6 +1054,8 @@ openframelayout.AddChidren(horizontalSeekBarRow); var horizontalSeekBarVol = new DiyImageSeekBar { + Y = openrowlayout.Bottom, + X = Application.GetRealWidth(80), Width = Application.GetRealWidth(920), Height = Application.GetRealHeight(160), IsProgressTextShow = true,//鏄剧ず鐧惧垎姣� @@ -1061,12 +1063,12 @@ ProgressBarColor = ZigbeeColor.Current.LogicProgressColorSelected,//閫変腑杩涘害鏉¢鑹� ThumbImagePath = "ZigeeLogic/progressbtn2.png",//杩涘害鏉℃寜閽浘鏍� ThumbImageHeight = Application.GetRealHeight(56),//杩涘害鏉℃寜閽浘鏍囩殑楂樺害锛堥粯璁ゆ鏂瑰舰锛氬鍜岄珮涓�鏍凤級 - ProgressTextColor = ZigbeeColor.Current.LogicBtnCancelColor,//杩涘害鏉″師棰滆壊 + ProgressTextColor = ZigbeeColor.Current.LogicBtnCancelColor, ProgressTextSize = 13,//鏄剧ず鐧惧垎姣斿瓧浣撳ぇ灏� SeekBarViewHeight = Application.GetRealHeight(10),//杩涘害鏉$殑楂樺害 }; - horizontalSeekBarRow.AddChidren(horizontalSeekBarVol); + openframelayout.AddChidren(horizontalSeekBarVol); #endregion #region 鍏� @@ -1138,24 +1140,26 @@ #endregion int Progressvalue = 100; - horizontalSeekBarVol.OnProgressChangedEvent += (sender, e) => - { - SelectedDeviceStatusaction = "yes"; - Progressvalue = horizontalSeekBarVol.Progress; - if (switchdictionary.ContainsKey("TaskType")) - { - switchdictionary.Remove("TaskType"); - } - if (switchdictionary.ContainsKey("Data1")) - { - switchdictionary.Remove("Data1"); - } - switchdictionary.Add("TaskType", "3"); + EventHandler<int> progressclick = (sender, e) => + { + SelectedDeviceStatusaction = "yes"; + Progressvalue = horizontalSeekBarVol.Progress; + if (switchdictionary.ContainsKey("TaskType")) + { + switchdictionary.Remove("TaskType"); + } + if (switchdictionary.ContainsKey("Data1")) + { + switchdictionary.Remove("Data1"); + } + switchdictionary.Add("TaskType", "3"); //鏈�澶т寒搴﹀�兼槸254闇�瑕佽浆鎹紱 var lightbrightnessvalue = (254 * horizontalSeekBarVol.Progress) / 100; - switchdictionary.Add("Data1", lightbrightnessvalue.ToString()); + switchdictionary.Add("Data1", lightbrightnessvalue.ToString()); - }; + }; + horizontalSeekBarVol.OnProgressChangedEvent += progressclick; + horizontalSeekBarVol.OnStopTrackingTouchEvent += progressclick; ///纭浜嬩欢 EventHandler<MouseEventArgs> openclick = (sender, e) => { @@ -1352,6 +1356,8 @@ openframelayout.AddChidren(horizontalSeekBarRow); var horizontalSeekBarVol = new DiyImageSeekBar { + Y = openrowlayout.Bottom, + X = Application.GetRealWidth(80), Width = Application.GetRealWidth(920), Height = Application.GetRealHeight(160), IsProgressTextShow = true,//鏄剧ず鐧惧垎姣� @@ -1361,9 +1367,9 @@ ThumbImageHeight = Application.GetRealHeight(56),//杩涘害鏉℃寜閽浘鏍囩殑楂樺害锛堥粯璁ゆ鏂瑰舰锛氬鍜岄珮涓�鏍凤級 ProgressTextColor = ZigbeeColor.Current.LogicBtnCancelColor,//杩涘害鏉″師棰滆壊 ProgressTextSize = 14,//鏄剧ず鐧惧垎姣斿瓧浣撳ぇ灏� - SeekBarViewHeight = Application.GetRealHeight(10),//杩涘害鏉$殑楂樺害 + SeekBarViewHeight = Application.GetRealHeight(10), }; - horizontalSeekBarRow.AddChidren(horizontalSeekBarVol); + openframelayout.AddChidren(horizontalSeekBarVol); #endregion @@ -1403,7 +1409,8 @@ #endregion int Progressvalue = 100; - horizontalSeekBarVol.OnProgressChangedEvent += (sender, e) => + + EventHandler<int> progressclick = (sender, e) => { SelectedDeviceStatusaction = "yes"; Progressvalue = horizontalSeekBarVol.Progress; @@ -1419,8 +1426,10 @@ switchdictionary.Add("Data2", horizontalSeekBarVol.Progress.ToString()); }; + horizontalSeekBarVol.OnProgressChangedEvent += progressclick; + horizontalSeekBarVol.OnStopTrackingTouchEvent += progressclick; ///纭浜嬩欢 - EventHandler<MouseEventArgs> openclick = (sender, e) => + EventHandler <MouseEventArgs> openclick = (sender, e) => { SelectedDeviceStatusaction = "yes"; horizontalSeekBarVol.IsClickable = true; @@ -1737,7 +1746,7 @@ } } break; - + ///绌鸿皟 case DeviceType.Thermostat: { @@ -1872,8 +1881,7 @@ var closeBtnSelected = new SelectedButton(); closerowlayout.AddChidren(closeBtnSelected); #endregion - - + mUIPickerView.OnSelectChangeEvent += (s1, s2, s3) => { @@ -1892,12 +1900,13 @@ } }; - - #endregion + + #endregion //榛樿26,鑷姩,涓 int indextemperature = 10, indexmode = 2, indexspeed = 1; if (edit && TaskList != null) { + foreach (var value in TaskList) { if (TaskList.Count == 1) @@ -2039,6 +2048,7 @@ ///鍙栨秷浜嬩欢 EventHandler<MouseEventArgs> closeclick = (sender, e) => { + //娓呴櫎涔嬪墠鏁版嵁锛� taskListInfo.Clear(); dictionary(modedictionary, "TaskType", "5"); -- Gitblit v1.8.0