old mode 100755
new mode 100644
| | |
| | | /// </summary>
|
| | | void LoadEvet_ChangeFadeTime()
|
| | | {
|
| | | barFadeTime.OnProgressChangedEvent = (sender, e) =>
|
| | | barFadeTime.OnStopTrackingTouchEvent = (sender, e) =>
|
| | | {
|
| | | light.fadeTime = e;
|
| | | light.SaveFunctionData(true);
|
| | |
| | | {
|
| | | barColorTemplatrue.OnProgressChangedEvent += (sender, value) =>
|
| | | {
|
| | | //设置自定义的文本
|
| | | barColorTemplatrue.SetCustomText(value * 100 + "K");
|
| | | new System.Threading.Thread(() => |
| | | { |
| | | Application.RunOnMainThread(() => |
| | | { |
| | | //设置自定义的文本 |
| | | barColorTemplatrue.SetCustomText(value * 100 + "K"); |
| | | light.Attr_CCT.curValue = value * 100; |
| | | System.Collections.Generic.Dictionary<string, string> d = new System.Collections.Generic.Dictionary<string, string>(); |
| | | d.Add(FunctionAttributeKey.CCT, light.Attr_CCT.curValue.ToString()); |
| | | Control.Ins.SendWriteCommand(light, d); |
| | | });
|
| | | System.Threading.Thread.Sleep(200);
|
| | | }).Start();
|
| | | };
|
| | | }
|
| | |
|
| | |
| | |
|
| | | if (e == 0 || e == 100)
|
| | | {
|
| | | //Control.Send(CommandType_A.write, this.light);
|
| | | System.Collections.Generic.Dictionary<string, string> d = new System.Collections.Generic.Dictionary<string, string>();
|
| | | d.Add(FunctionAttributeKey.Brightness, light.brightness.ToString());
|
| | | Control.Ins.SendWriteCommand(light, d);
|
| | |
| | | light.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, light.trait_on_off.curValue.ToString());
|
| | | d.Add(FunctionAttributeKey.FadeTime, light.fadeTime.ToString()); |
| | | if (btnSwitch.IsSelected)
|
| | | {
|
| | | d.Add(FunctionAttributeKey.Brightness, light.lastBrightness.ToString());
|