黄学彪
2020-12-16 0d9f64668fd7350d6a21fd157e32009a96d98134
ZigbeeApp/Shared/Phone/MainPage/UnallocatedRoomForm.cs
@@ -271,7 +271,7 @@
                //设备的背景容器
                var frameDeviceBack = new FrameLayout();
                frameDeviceBack.X = ControlCommonResourse.XXLeft;
                frameDeviceBack.X = HdlControlResourse.XXLeft;
                frameDeviceBack.Y = Application.GetRealHeight(369);
                frameDeviceBack.BackgroundColor = UserCenterColor.Current.White;
                frameDeviceBack.Width = bodyFrameLayout.Width;
@@ -300,7 +300,7 @@
        {
            //头部的白色背景
            var functionBack1 = new FrameLayout();
            functionBack1.X = ControlCommonResourse.XXLeft;
            functionBack1.X = HdlControlResourse.XXLeft;
            functionBack1.Y = Application.GetRealHeight(55);
            functionBack1.Height = Application.GetRealHeight(160);
            functionBack1.Width = Application.GetRealWidth(1028);
@@ -308,7 +308,7 @@
            DeviceBodyTableControl.AddChidren(functionBack1);
            functionBack1.SetCornerWithSameRadius(Application.GetRealHeight(17), HDLUtils.RectCornerTopLeft);
            var functionBack2 = new FrameLayout();
            functionBack2.X = ControlCommonResourse.XXLeft;
            functionBack2.X = HdlControlResourse.XXLeft;
            functionBack2.Y = functionBack1.Bottom - Application.GetRealHeight(50);
            functionBack2.Height = Application.GetRealHeight(279 - 160 + 50);
            functionBack2.Width = Application.GetRealWidth(1028);
@@ -318,7 +318,7 @@
            //左右滑动的控件
            var HorizontalView = new HorizontalScrolViewLayout();
            HorizontalView.X = Application.GetRealWidth(CommonFormResouce.X_Left);
            HorizontalView.X = HdlControlResourse.XXLeft;
            HorizontalView.Y = Application.GetRealHeight(55);
            HorizontalView.Height = Application.GetRealHeight(279);
            HorizontalView.Width = Application.GetRealWidth(1028);
@@ -391,7 +391,7 @@
            //初始化设备列表控件
            foreach (var deviceKey in rowInfo.listDeviceKeys)
            {
                var device = LocalDevice.Current.GetDevice(deviceKey);
                var device = HdlDeviceCommonLogic.Current.GetDevice(deviceKey);
                var deviceRow = new Controls.DeviceSelectUnallocatedControl(listDeviceView.rowSpace / 2);
                listDeviceView.AddChidren(deviceRow);
                deviceRow.InitControl(device);
@@ -489,12 +489,12 @@
                            if (this.canSelectAll == true)
                            {
                                //添加缓存
                                dicSelectDevice[LocalDevice.Current.GetDeviceMainKeys(device)] = device;
                                dicSelectDevice[HdlDeviceCommonLogic.Current.GetDeviceMainKeys(device)] = device;
                            }
                            else
                            {
                                //移除缓存
                                dicSelectDevice.Remove(LocalDevice.Current.GetDeviceMainKeys(device));
                                dicSelectDevice.Remove(HdlDeviceCommonLogic.Current.GetDeviceMainKeys(device));
                            }
                        }
                    }
@@ -634,11 +634,11 @@
            //全部的设备
            var listDevice = HdlRoomLogic.Current.GetUnalloctedDevice();
            //根据设备所属类型排序
            listDevice = LocalDevice.Current.SortDeviceByBelongType(listDevice);
            listDevice = HdlDeviceCommonLogic.Current.SortDeviceByBelongType(listDevice);
            var dic = new Dictionary<string, DeviceRowInfo>();
            foreach (var device in listDevice)
            {
                var typeInfo = LocalDevice.Current.GetDeviceBelongEnumInfo(device);
                var typeInfo = HdlDeviceCommonLogic.Current.GetDeviceBelongEnumInfo(device);
                //按所属ID分组
                if (dic.ContainsKey(typeInfo.BeloneText) == false)
                {
@@ -646,12 +646,12 @@
                    string path1 = string.Empty;
                    string path2 = string.Empty;
                    //获取图片
                    Common.LocalDevice.Current.GetDeviceFunctionTypeMenuIcon(typeInfo, ref path1, ref path2);
                    HdlDeviceCommonLogic.Current.GetDeviceFunctionTypeMenuIcon(typeInfo, ref path1, ref path2);
                    dic[typeInfo.BeloneText].IconPath = path1;
                    dic[typeInfo.BeloneText].IconPathSelected = path2;
                    dic[typeInfo.BeloneText].Text = typeInfo.BeloneText;
                }
                dic[typeInfo.BeloneText].listDeviceKeys.Add(LocalDevice.Current.GetDeviceMainKeys(device));
                dic[typeInfo.BeloneText].listDeviceKeys.Add(HdlDeviceCommonLogic.Current.GetDeviceMainKeys(device));
            }
            return dic;
        }