| | |
| | | }; |
| | | setTempBar.OnStopTrackingTouchEvent = (sender, e) => { |
| | | temp = e; |
| | | Dictionary<string, string> d = new Dictionary<string, string>(); |
| | | device.SetAttrState(FunctionAttributeKey.SetTemp, e.ToString()); |
| | | if (setTempAttr.step == "0.5") |
| | | { |
| | | e = e / 2; |
| | | btnTemp.Text = (setTempAttr.min + ((double)e)).ToString("0.0"); |
| | | double ex = (double)e / 2; |
| | | btnTemp.Text = (setTempAttr.min + ((double)ex)).ToString("0.0"); |
| | | d.Add(FunctionAttributeKey.SetTemp, (setTempAttr.min + ex).ToString()); |
| | | } |
| | | else |
| | | { |
| | | btnTemp.Text = (setTempAttr.min + e).ToString(); |
| | | d.Add(FunctionAttributeKey.SetTemp, (setTempAttr.min + e).ToString()); |
| | | } |
| | | |
| | | #if __IOS__ |
| | |
| | | #endif |
| | | btnTempUint.X = btnTemp.Right; |
| | | controlTime = DateTime.Now; |
| | | Dictionary<string, string> d = new Dictionary<string, string>(); |
| | | d.Add(FunctionAttributeKey.SetTemp, (setTempAttr.min + e).ToString()); |
| | | Control.Ins.SendWriteCommand(device, d); |
| | | }; |
| | | |