wxr
2022-03-11 b079d370b3c23751a5d200dc2d25f6c80977b4d4
HDL_ON/UI/UI2/FuntionControlView/Light/RGBPageBLL.cs
@@ -88,6 +88,16 @@
        /// </summary>
        void LoadColorChangeEvent()
        {
            if (!function.online)
            {
                new Tip()
                {
                    CloseTime = 1,
                    Text = Language.StringByID(StringId.DeviceOfflineCannotOption),
                    Direction = AMPopTipDirection.None,
                }.Show(MainPage.BaseView);
                return;
            }
            DateTime colorChangeTime = DateTime.MinValue;
            //bool send = false;
@@ -202,11 +212,21 @@
        /// </summary>
        void LoadEvent_DimmerBar()
        {
            dimmerBar.OnStartTrackingTouchEvent = (sender, e)=>{
                onDimmerBar = true;
            };
            dimmerBar.OnStopTrackingTouchEvent = (sender, e) => {
                new System.Threading.Thread(() => {
            dimmerBar.OnStopTrackingTouchEvent = (sender, e) =>
            {
                if (!function.online)
                {
                    new Tip()
                    {
                        CloseTime = 1,
                        Text = Language.StringByID(StringId.DeviceOfflineCannotOption),
                        Direction = AMPopTipDirection.None,
                    }.Show(MainPage.BaseView);
                    return;
                }
                new System.Threading.Thread(() =>
                {
                    System.Threading.Thread.Sleep(200);
                    onDimmerBar = false;
                })
@@ -217,7 +237,14 @@
               
                Control.Ins.SendWriteCommand(function, d);
            };
            dimmerBar.OnProgressChangedEvent = (sender, e) => {
            if (function.online)
            {
                dimmerBar.OnStartTrackingTouchEvent = (sender, e) =>
                {
                    onDimmerBar = true;
                };
                dimmerBar.OnProgressChangedEvent = (sender, e) =>
                {
                //function.fadeTime = 0;
                //if (!btnSwitch.IsSelected)
                //{
@@ -254,7 +281,7 @@
                //}
            };
        }
        }
        /// <summary>
        /// 修改灯光渐变时间
        /// </summary>
@@ -309,6 +336,10 @@
        {
            btnRestoredPoint.MouseUpEventHandler = (sender, e) =>
            {
                if (!function.online)
                {
                    return;
                }
                if(function.trait_on_off.curValue.ToString() == "off")
                {
                    return;