From 45e4e387f3ef259b9e225fdd543e20be285a5112 Mon Sep 17 00:00:00 2001 From: WJC <wjc@hdlchina.com.cn> Date: 星期二, 29 十月 2019 13:42:57 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/dev-tzy' into dev-wjc --- ZigbeeApp/Shared/Phone/Device/Curtain/RollerShadeControl.cs | 18 +++++++++--------- 1 files changed, 9 insertions(+), 9 deletions(-) diff --git a/ZigbeeApp/Shared/Phone/Device/Curtain/RollerShadeControl.cs b/ZigbeeApp/Shared/Phone/Device/Curtain/RollerShadeControl.cs index 28f9330..ded3c3d 100755 --- a/ZigbeeApp/Shared/Phone/Device/Curtain/RollerShadeControl.cs +++ b/ZigbeeApp/Shared/Phone/Device/Curtain/RollerShadeControl.cs @@ -107,29 +107,29 @@ { return; } - if ((common as Rollershade).DeviceStatusReport.CluterID == 258) + if (common.DeviceStatusReport.CluterID == 258) { - if ((common as Rollershade).DeviceStatusReport.AttriBute[0].AttributeId == 8) + if (common.DeviceStatusReport.AttriBute[0].AttributeId == 8) { //绐楀笜鐧惧垎姣� var rollerShade = deviceUI.CommonDevice as Rollershade; - rollerShade.DeviceStatusReport = (common as Rollershade).DeviceStatusReport; - rollerShade.WcdCurrentPositionLiftPercentage = (common as Rollershade).DeviceStatusReport.AttriBute[0].AttriButeData; + rollerShade.DeviceStatusReport = common.DeviceStatusReport; + rollerShade.WcdCurrentPositionLiftPercentage = common.DeviceStatusReport.AttriBute[0].AttriButeData; SeekBar.Progress = rollerShade.WcdCurrentPositionLiftPercentage; seekBarTitle.Text = $"{SeekBar.Progress} %"; rollerShade.LastDateTime = DateTime.Now; } - else if ((common as Rollershade).DeviceStatusReport.AttriBute[0].AttributeId == 0) + else if (common.DeviceStatusReport.AttriBute[0].AttributeId == 0) { //绐楀笜绫诲瀷 var rollerShade = deviceUI.CommonDevice as Rollershade; - rollerShade.DeviceStatusReport = (common as Rollershade).DeviceStatusReport; - rollerShade.WcdType = (common as Rollershade).DeviceStatusReport.AttriBute[0].AttriButeData; + rollerShade.DeviceStatusReport = common.DeviceStatusReport; + rollerShade.WcdType = common.DeviceStatusReport.AttriBute[0].AttriButeData; rollerShade.LastDateTime = DateTime.Now; } } //***鏂版敼***璁惧鐘舵�佷笂鎶ヤ腑锛屽綋CluterID=3,璇佹槑璁惧鍦ㄧ嚎锛岀洿鎺ユ爣璁� - else if ((common as Rollershade).DeviceStatusReport.CluterID == 3) + else if (common.DeviceStatusReport.CluterID == 3) { var rollerShade = deviceUI.CommonDevice as Rollershade; rollerShade.IsOnline = 1; @@ -161,7 +161,7 @@ return; } var rollerShade = deviceUI.CommonDevice as Rollershade; - rollerShade.IsOnline = (common as Rollershade).IsOnline; + rollerShade.IsOnline = common.IsOnline; rollerShadeIMG.IsSelected = rollerShade.IsOnline == 1; rollerShade.LastDateTime = DateTime.Now; } -- Gitblit v1.8.0