gxc
2020-02-28 66a9965c44ecc32a6696abca876ab9d1cd091584
ZigbeeApp/Shared/Phone/Device/Category/SelectDevice.cs
old mode 100755 new mode 100644
@@ -31,6 +31,10 @@
        /// </summary>
        private Button floorBtn;
        /// <summary>
        /// 当前楼层id
        /// </summary>
        private string curFloorId;
        /// <summary>
        /// 选择楼层
        /// </summary>
        private Button selectFloorBtn;
@@ -153,7 +157,7 @@
                    || info.BeloneType == DeviceBeloneType.A插座 || info.BeloneType == DeviceBeloneType.A智能空开
                    || info.BeloneType == DeviceBeloneType.A灯光 || info.BeloneType == DeviceBeloneType.A空调
                    || info.BeloneType == DeviceBeloneType.A窗帘 || info.BeloneType == DeviceBeloneType.A继电器
                    || info.BeloneType == DeviceBeloneType.A调光器
                    || info.BeloneType == DeviceBeloneType.A调光器
                    )
                {
                    if (typeDeviceDic.ContainsKey(info.BeloneTextId) == false)
@@ -226,9 +230,12 @@
        {
            var floors = new SelectFloor();
            AddChidren(floors);
            floors.changeFloor = false;
            floors.CurFloorId = curFloorId;
            floors.Init(580, 184, Direction.Right);
            floors.FloorAction += (floorId) =>
            {
                curFloorId = floorId;
                floorBtn.Text = Config.Instance.Home.GetFloorNameById(floorId);
                RefreshBodyView(floorId);
            };
@@ -426,7 +433,7 @@
            var sameTypeList = new List<DeviceUI> { };
            sameTypeList = typeDeviceDic[int.Parse((typeSender as Button).Tag.ToString())];
            foreach (var device in sameTypeList)
            {
                if (beforeSceneTargetDeviceUIs.Find((obj) => obj.DeviceUI.DeviceEpoint == device.DeviceEpoint && obj.DeviceUI.DeviceAddr == device.DeviceAddr) != null)
@@ -441,11 +448,13 @@
                deviceListScrolView.AddChidren(deviceTypeRowLayout);
                var deviceRow = new FunctionRow(0, 35);
                deviceTypeRowLayout.AddChidren(deviceRow);
                deviceRow.Init(device.IconPath, device.OnlineIconPath, true);
                deviceRow.SetTitle(device.CommonDevice.DeviceEpointName);
                deviceRow.SetTitle(Common.LocalDevice.Current.GetDeviceEpointName(device.CommonDevice));
                deviceRow.IsSelected = true;
                deviceRow.HideSwitchBtn(false);
                deviceRow.NameBtn.BackgroundColor = ZigbeeColor.Current.GXCRedColor;
                deviceTypeRowLayout.AddChidren(deviceRow);
                deviceRow.ClickBtn.MouseUpEventHandler += (sender, e) =>
                {
@@ -578,7 +587,7 @@
                Gravity = Gravity.CenterHorizontal,
                TextColor = ZigbeeColor.Current.GXCTextBlackColor,
                TextSize = 16,
                Text = device.CommonDevice.DeviceEpointName
                Text = Common.LocalDevice.Current.GetDeviceEpointName(device.CommonDevice)
            };
            titleFL.AddChidren(deviceName);
@@ -734,7 +743,7 @@
                Gravity = Gravity.CenterHorizontal,
                TextColor = ZigbeeColor.Current.GXCTextBlackColor,
                TextSize = 16,
                Text = device.CommonDevice.DeviceEpointName
                Text = Common.LocalDevice.Current.GetDeviceEpointName(device.CommonDevice)
            };
            titleFL.AddChidren(deviceName);
@@ -787,7 +796,7 @@
                dialog.RemoveFromParent();
            };
            open.SeekBar.ProgressChanged += (sender, e) =>
            open.SeekBar.OnProgressChangedEvent += (sender, e) =>
            {
                open.IsSelected = true;
                shut.IsSelected = false;
@@ -805,7 +814,7 @@
                {
                    open.IsSelected = true;
                    shut.IsSelected = false;
                    open.SetProgress(sceneTarget.TaskList[0].Data2);
                    open.SetSeekBarProgress(sceneTarget.TaskList[0].Data2);
                }
            }
@@ -900,7 +909,7 @@
                TextColor = ZigbeeColor.Current.GXCTextBlackColor,
                TextSize = 16,
                TextAlignment = TextAlignment.CenterLeft,
                Text = device.CommonDevice.DeviceEpointName
                Text = Common.LocalDevice.Current.GetDeviceEpointName(device.CommonDevice)
            };
            titleFL.AddChidren(deviceName);
@@ -953,7 +962,7 @@
                dialog.RemoveFromParent();
            };
            open.SeekBar.ProgressChanged += (sender, e) =>
            open.SeekBar.OnProgressChangedEvent += (sender, e) =>
            {
                open.IsSelected = true;
                shut.IsSelected = false;
@@ -971,7 +980,7 @@
                {
                    open.IsSelected = true;
                    shut.IsSelected = false;
                    open.SetProgress(sceneTarget.TaskList[0].Data1);
                    open.SetSeekBarProgress(sceneTarget.TaskList[0].Data1);
                }
            }
@@ -1066,7 +1075,7 @@
                TextColor = ZigbeeColor.Current.GXCTextBlackColor,
                TextSize = 16,
                TextAlignment = TextAlignment.CenterLeft,
                Text = device.CommonDevice.DeviceEpointName
                Text = Common.LocalDevice.Current.GetDeviceEpointName(device.CommonDevice)
            };
            titleFL.AddChidren(deviceName);