From 9d3c2727f1cd12f0a29c75f4ddff851d5243ac81 Mon Sep 17 00:00:00 2001
From: 黄学彪 <hxb@hdlchina.com.cn>
Date: 星期四, 16 四月 2020 18:29:38 +0800
Subject: [PATCH] 新版本
---
ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceMacInfoEditorForm.cs | 38 ++++++++++++++++++++++++++++++--------
1 files changed, 30 insertions(+), 8 deletions(-)
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceMacInfoEditorForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceMacInfoEditorForm.cs
index 2dba546..4722fd7 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceMacInfoEditorForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceMacInfoEditorForm.cs
@@ -20,7 +20,7 @@
/// <summary>
/// 鍒楄〃鎺т欢
/// </summary>
- private VerticalListControl listview = null;
+ private FrameListControl listview = null;
/// <summary>
/// 璁惧鐨勮澶囩被鍨�
/// </summary>
@@ -81,15 +81,19 @@
//娓呯┖bodyFrame
this.ClearBodyFrame();
+ var listBackControl = new VerticalFrameControl();
+ listBackControl.Height = bodyFrameLayout.Height;
+ bodyFrameLayout.AddChidren(listBackControl);
+
//鍒濆鍖栨甯�
var tableContr = new InformationEditorControl();
- this.listview = tableContr.InitControl(bodyFrameLayout, Language.StringByID(R.MyInternationalizationString.uInfoEditor), 369, 1368);
+ this.listview = tableContr.InitControl(listBackControl.frameTable, Language.StringByID(R.MyInternationalizationString.uInfoEditor), 1368);
//鍥剧墖
var btnPic = new DeviceInfoIconControl();
btnPic.Y = Application.GetRealHeight(92);
btnPic.Gravity = Gravity.CenterHorizontal;
- bodyFrameLayout.AddChidren(btnPic);
+ listBackControl.frameTable.AddChidren(btnPic);
btnPic.InitControl(listNewDevice[0]);
//璁惧澶囨敞
@@ -171,7 +175,7 @@
this.AddAllMenuRow();
//鍒濆鍖栨甯冨畬鎴�
- tableContr.FinishInitControl(bodyFrameLayout, this.listview);
+ tableContr.FinishInitControl();
tableContr = null;
//淇濆瓨
@@ -303,7 +307,7 @@
};
actionNone = () =>
{
- Shared.Phone.UserCenter.DoorLock.DoorLockCommonLayout.SecurityRequest(doorLock, action);
+ Shared.Phone.UserCenter.DoorLock.DoorLockCommonLayout.SecurityRequest(doorLock);
};
HdlCheckLogic.Current.CheckSecondarySecurity(action, actionNone);
}
@@ -324,7 +328,7 @@
};
actionNone = () =>
{
- Shared.Phone.UserCenter.DoorLock.DoorLockCommonLayout.SecurityRequest(doorLock, action);
+ Shared.Phone.UserCenter.DoorLock.DoorLockCommonLayout.SecurityRequest(doorLock);
};
HdlCheckLogic.Current.CheckSecondarySecurity(action, actionNone);
@@ -928,10 +932,19 @@
var title = Language.StringByID(R.MyInternationalizationString.uSelectFunctionType);
var form = new BottomItemSelectForm();
+ form.CancelCallEvent = true;//鍏佽鍙栨秷
form.AddForm(title, listText, nowSelectNo);
form.FinishSelectEvent += (selectNo) =>
{
- btnFunction.Text = listText[selectNo];
+ if (selectNo == -1)
+ {
+ //閫夋嫨鍙栨秷
+ btnFunction.Text = string.Empty;
+ }
+ else
+ {
+ btnFunction.Text = listText[selectNo];
+ }
nowSelectNo = selectNo;
//璁板綍璧峰綋鍓嶉�夋嫨鐨勫姛鑳界被鍨�
if (selectNo == 0)
@@ -952,7 +965,7 @@
this.listNewDevice[0].IconPath = "Device/Light.png";
}
}
- else
+ else if (selectNo == 2)
{
this.listNewDevice[0].DfunctionType = DeviceFunctionType.A鎻掑骇;
if (this.listNewDevice[0].IsCustomizeImage == false)
@@ -961,6 +974,15 @@
this.listNewDevice[0].IconPath = "Device/Socket1.png";
}
}
+ else
+ {
+ this.listNewDevice[0].DfunctionType = DeviceFunctionType.A鏈畾涔�;
+ if (this.listNewDevice[0].IsCustomizeImage == false)
+ {
+ //閲嶆柊璁剧疆鍥剧墖
+ this.listNewDevice[0].IconPath = "Device/Switch.png";
+ }
+ }
this.listNewDevice[0].ReSave();
};
};
--
Gitblit v1.8.0