From 587c36e27131f2d028fcabc13b296a8de7470034 Mon Sep 17 00:00:00 2001
From: gxc <guoxuecheng@guoxuechengdeMacBook-Pro.local>
Date: 星期三, 08 一月 2020 08:59:19 +0800
Subject: [PATCH] 2019.1.8
---
ZigbeeApp/Shared/Phone/UserCenter/Safety/AlarmTargetAddMenuForm.cs | 47 +++++++----------------------------------------
1 files changed, 7 insertions(+), 40 deletions(-)
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Safety/AlarmTargetAddMenuForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Safety/AlarmTargetAddMenuForm.cs
index 3a1f691..626e387 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Safety/AlarmTargetAddMenuForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Safety/AlarmTargetAddMenuForm.cs
@@ -156,7 +156,7 @@
btnIconContr.ButtonClickEvent += (sender, e) =>
{
//妤煎眰鑿滃崟
- var contr = new TopRightMenuControl(dicFloor.Count, 449, Language.StringByID(R.MyInternationalizationString.SelectFloor));
+ var contr = new TopRightMenuControl(dicFloor.Count, 2, Language.StringByID(R.MyInternationalizationString.SelectFloor));
foreach (var floorId in dicFloor.Keys)
{
contr.AddRowMenu(dicFloor[floorId], "Floor/Floor.png", "Floor/FloorSelected.png", () =>
@@ -288,46 +288,13 @@
string unSelectPath = string.Empty;
string selectPath = string.Empty;
- var typeInfo = Common.LocalDevice.Current.GetNotHdlMyDeviceEnumInfo(new List<CommonDevice>() { device });
- if (device.Type == DeviceType.OnOffOutput)
+ var typeInfo = Common.LocalDevice.Current.GetDeviceBelongEnumInfo(device);
+ //鑾峰彇鍥剧墖
+ Common.LocalDevice.Current.GetDeviceObjectIcon(typeInfo.ConcreteType, ref unSelectPath, ref selectPath);
+ if (dicRoomData.ContainsKey(typeInfo.BeloneTextId) == false)
{
- //缁х數鍣ㄧ殑鏃跺��,闇�瑕佺壒娈婂鐞�
- if (device.DfunctionType == DeviceFunctionType.A寮�鍏�)
- {
- typeInfo.BeloneTextId = R.MyInternationalizationString.uSwitch;
- unSelectPath = "Device/Switch.png";
- }
- else if (device.DfunctionType == DeviceFunctionType.A鎻掑骇)
- {
- typeInfo.BeloneTextId = R.MyInternationalizationString.uSocket1;
- unSelectPath = "Device/Socket1.png";
- }
- else if (device.DfunctionType == DeviceFunctionType.A鐏厜)
- {
- typeInfo.BeloneTextId = R.MyInternationalizationString.uLight;
- unSelectPath = "Device/Light.png";
- }
- else
- {
- //缁х數鍣�
- typeInfo.BeloneTextId = R.MyInternationalizationString.uDeviceBelongId2300;
- unSelectPath = "Device/Relay.png";
- }
- if (dicRoomData.ContainsKey(typeInfo.BeloneTextId) == false)
- {
- dicRoomData[typeInfo.BeloneTextId] = new uRowInformation();
- dicRoomData[typeInfo.BeloneTextId].IconPath = unSelectPath;
- }
- }
- else
- {
- //鑾峰彇鍥剧墖
- Common.LocalDevice.Current.GetDeviceBeloneIcon(typeInfo.ConcreteType, ref unSelectPath, ref selectPath);
- if (dicRoomData.ContainsKey(typeInfo.BeloneTextId) == false)
- {
- dicRoomData[typeInfo.BeloneTextId] = new uRowInformation();
- dicRoomData[typeInfo.BeloneTextId].IconPath = unSelectPath;
- }
+ dicRoomData[typeInfo.BeloneTextId] = new uRowInformation();
+ dicRoomData[typeInfo.BeloneTextId].IconPath = unSelectPath;
}
dicRoomData[typeInfo.BeloneTextId].listDevice.Add(device);
}
--
Gitblit v1.8.0