HDL Home App 第二版本 旧平台金堂用 正在使用
黄学彪
2019-11-07 82a773d1783549caca563831aac8affc059deedf
ZigbeeApp/Shared/Phone/Device/Category/Category.cs
@@ -714,6 +714,15 @@
            UserView.HomePage.Instance.PageIndex += 1;
            addLogicPage.Show();
        }
        /// <summary>
        /// HidenFloor
        /// </summary>
        /// <param name="statu"></param>
        private void HidenFloor(bool statu)
        {
            selectFloorBtn.Visible = !statu;
            floorBtn.Visible = !statu;
        }
        #endregion
@@ -726,14 +735,17 @@
            functionSceneAutoBodyView.RemoveAll();
            if (functionBtn.IsSelected)
            {
                HidenFloor(false);
                ShowFunction();
            }
            else if (sceneBtn.IsSelected)
            {
                HidenFloor(false);
                ShowScene();
            }
            else if (automationBtn.IsSelected)
            {
                HidenFloor(true);
                ShowAutotion();
            }
        }
@@ -945,13 +957,32 @@
                            deviceRow.ClickBtn.MouseUpEventHandler += (send2, e2) =>
                            {
                                var lightControl = new Phone.Device.Light.LightControl();
                                UserView.HomePage.Instance.AddChidren(lightControl);
                                UserView.HomePage.Instance.PageIndex += 1;
                                //lightControl.action = RefreshBodyView;
                                lightControl.Show(deviceUI, room);
                                if (deviceUI.CommonDevice.DfunctionType == DeviceFunctionType.A开关)
                                {
                                    var lightControl = new Phone.Device.Light.OnOffControl();
                                    UserView.HomePage.Instance.AddChidren(lightControl);
                                    UserView.HomePage.Instance.PageIndex += 1;
                                    //lightControl.action = RefreshBodyView;
                                    lightControl.Show(deviceUI, room);
                                }
                                else if (deviceUI.CommonDevice.DfunctionType == DeviceFunctionType.A插座)
                                {
                                    var lightControl = new Phone.Device.Light.PlugControl();
                                    UserView.HomePage.Instance.AddChidren(lightControl);
                                    UserView.HomePage.Instance.PageIndex += 1;
                                    //lightControl.action = RefreshBodyView;
                                    lightControl.Show(deviceUI, room);
                                }
                                else
                                {
                                    var lightControl = new Phone.Device.Light.LightControl();
                                    UserView.HomePage.Instance.AddChidren(lightControl);
                                    UserView.HomePage.Instance.PageIndex += 1;
                                    //lightControl.action = RefreshBodyView;
                                    lightControl.Show(deviceUI, room);
                                }
                            };
                            var editBtn = new CommonForm.RowLayoutEditButton()
                            {
                                Tag = deviceUI,
@@ -1284,6 +1315,7 @@
                                UserHomeView.ReadStatus(rollerShade, () =>
                                {
                                    rollerShade.ReadAttri(Cluster_ID.Identify, AttriButeId.Switch);
                                    rollerShade.ReadWcdCurrentPositionLiftPercentage();
                                });
                            }
                            else
@@ -1292,6 +1324,7 @@
                                if ((DateTime.Now - rollerShade.LastDateTime).TotalSeconds > CommonPage.ReadDeviceStatuSpan)
                                {
                                    rollerShade.ReadAttri(Cluster_ID.Identify, AttriButeId.Switch);
                                    rollerShade.ReadWcdCurrentPositionLiftPercentage();
                                }
                            }