黄学彪
2020-04-28 e22fdb94322e6cec38e5e4a9aec13d431a133fde
ZigbeeApp/Shared/Phone/Category/Controls/DeviceRow/DeviceCurtainRowControl.cs
@@ -61,6 +61,13 @@
            btnOpen.X = Application.GetRealWidth(625) - btnOpen.XOffset;
            btnOpen.ButtonClickEvent += (sender, e) =>
            {
                //如果住宅为虚拟住宅,直接修改缓存
                if (Common.Config.Instance.Home.IsVirtually == true)
                {
                    ((Rollershade)i_device).WcdCurrentPositionLiftPercentage = 100;
                    base.RefreshControlInfo(i_device);
                    return;
                }
                ((Rollershade)i_device).CurtainUpDownStopControl(0);
            };
@@ -74,7 +81,11 @@
            btnStop.X = Application.GetRealWidth(769) - btnOpen.XOffset;
            btnStop.ButtonClickEvent += (sender, e) =>
            {
                ((Rollershade)i_device).CurtainUpDownStopControl(2);
                //如果住宅为虚拟住宅,此功能无效
                if (Common.Config.Instance.Home.IsVirtually == false)
                {
                    ((Rollershade)i_device).CurtainUpDownStopControl(2);
                }
            };
            //关闭
@@ -85,6 +96,13 @@
            btnClose.X = Application.GetRealWidth(896) - btnOpen.XOffset;
            btnClose.ButtonClickEvent += (sender, e) =>
            {
                //如果住宅为虚拟住宅,直接修改缓存
                if (Common.Config.Instance.Home.IsVirtually == true)
                {
                    ((Rollershade)i_device).WcdCurrentPositionLiftPercentage = 0;
                    base.RefreshControlInfo(i_device);
                    return;
                }
                ((Rollershade)i_device).CurtainUpDownStopControl(1);
            };
@@ -134,6 +152,11 @@
        /// </summary>
        public override void SendStatuComand()
        {
            //如果住宅为虚拟住宅,此功能无效
            if (Common.Config.Instance.Home.IsVirtually == true)
            {
                return;
            }
            //检测能否发送获取状态命令
            if (this.CheckCanSendStatuComand() == true)
            {