From e22fdb94322e6cec38e5e4a9aec13d431a133fde Mon Sep 17 00:00:00 2001 From: 黄学彪 <hxb@hdlchina.com.cn> Date: 星期二, 28 四月 2020 16:32:35 +0800 Subject: [PATCH] 上传合并后的代码 --- ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceFunctionSettionForm.cs | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++++--- 1 files changed, 55 insertions(+), 3 deletions(-) diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceFunctionSettionForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceFunctionSettionForm.cs index 3a52b0e..bf36e95 100755 --- a/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceFunctionSettionForm.cs +++ b/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceFunctionSettionForm.cs @@ -87,7 +87,15 @@ //鍒濆鍖栨甯� this.tableContr = new InformationEditorControl(); - this.listview = tableContr.InitControl(listBackControl.frameTable, Language.StringByID(R.MyInternationalizationString.uDeviceEditor), 1128); + + if (this.deviceObj.Type == DeviceType.FreshAir) + { + this.listview = tableContr.InitControl(listBackControl.frameTable, Language.StringByID(R.MyInternationalizationString.uDeviceEditor), 1028); + } + else + { + this.listview = tableContr.InitControl(listBackControl.frameTable, Language.StringByID(R.MyInternationalizationString.uDeviceEditor), 1128); + } //鍒濆鍖栬澶囧洖璺浘鏍� this.InitDeviceEpointIcon(listBackControl); @@ -149,6 +157,10 @@ else if (device.DfunctionType == DeviceFunctionType.A鐏厜) { device.IconPath = "Device/Light.png"; + } + else + { + device.IconPath = "Device/RelayEpoint.png"; } device.ReSave(); } @@ -338,10 +350,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) @@ -352,13 +373,31 @@ { dicDeviceFuncType[nowSelectDevice.DeviceEpoint] = DeviceFunctionType.A鐏厜; } - else + else if (selectNo == 2) { dicDeviceFuncType[nowSelectDevice.DeviceEpoint] = DeviceFunctionType.A鎻掑骇; + } + else + { + dicDeviceFuncType[nowSelectDevice.DeviceEpoint] = DeviceFunctionType.A鏈畾涔�; } }; }; } + } + + //濡傛灉鏄柊椋� + if (nowSelectDevice.Type == DeviceType.FreshAir) + { + //鍔熻兘绫诲瀷 + string caption = Language.StringByID(R.MyInternationalizationString.uFunctionType); + string strType = Language.StringByID(R.MyInternationalizationString.FreshAir); + var btnFunction = new FrameCaptionViewControl(caption, strType, listview.rowSpace / 2); + btnFunction.UseClickStatu = false; + listview.AddChidren(btnFunction); + btnFunction.InitControl(); + //搴曠嚎 + btnFunction.AddBottomLine(); } } @@ -413,6 +452,19 @@ if (listIcon.Count == 1) { frame.Gravity = Gravity.CenterVertical; + + //濡傛灉鏄柊椋� + if (deviceObj.Type == DeviceType.FreshAir) + { + frame.RemoveFromParent(); + frameBorder.Y = Application.GetRealHeight(0); + frameBorder.Height = Application.GetRealHeight(709); + frameBack.BackgroundImagePath = "FreshAir/FreshAirRealDevicePic.png"; + frameBack.Width = this.GetPictrueRealSize(878); + frameBack.Height = this.GetPictrueRealSize(354); + frameBack.Y = Application.GetRealHeight(153); + frameBack.Gravity = Gravity.Center; + } } else { -- Gitblit v1.8.0