| | |
| | | TextAlignment = TextAlignment.Center, |
| | | }; |
| | | fLayout.AddChidren(text1Btn); |
| | | //可到分类-功能-电器操作使用 |
| | | //可到分类-功能-操作使用 |
| | | Button text2Btn = new Button |
| | | { |
| | | Width = Application.GetRealWidth(375 - 32), |
| | |
| | | this.AddChidren(namePatchView.FLayoutView()); |
| | | namePatchView.btnText1.TextID = StringId.yaokongqimingcheng; |
| | | namePatchView.btnText2.Text = control.name; |
| | | namePatchView.btnClick.MouseUpEventHandler += (sender,e) => { |
| | | |
| | | //所属区域 |
| | | View.PatchView quyuPatchView = new View.PatchView(); |
| | | quyuPatchView.frameLayout.Y = namePatchView.frameLayout.Bottom; |
| | | this.AddChidren(quyuPatchView.FLayoutView()); |
| | | quyuPatchView.btnText1.TextID = StringId.suoshuquyu; |
| | | quyuPatchView.btnText2.Text=Intelligence.Automation.LogicMethod.GetGetRoomName(function); |
| | | |
| | | //继续添加 |
| | | Button addBtn = new Button |
| | | { |
| | | Y = quyuPatchView.frameLayout.Bottom + Application.GetRealHeight(125), |
| | | X = Application.GetRealWidth(16), |
| | | Width = Application.GetRealWidth(375 - 32), |
| | | Height = Application.GetRealHeight(20), |
| | | TextID = StringId.jixutianjia, |
| | | TextSize = TextSize.text14, |
| | | TextColor = CSS.CSS_Color.textConfirmColor, |
| | | TextAlignment = TextAlignment.Center, |
| | | }; |
| | | this.AddChidren(addBtn); |
| | | //完成 |
| | | View.SaveView saveView = new View.SaveView(); |
| | | this.AddChidren(saveView.FLayoutView()); |
| | | saveView.frameLayout.SetCornerWithSameRadius(Application.GetRealHeight(24), HDLUtils.RectCornerTopLeft | HDLUtils.RectCornerTopRight); |
| | | #endregion |
| | | #region 界面点击事件 |
| | | //遥控器名称点击事件 |
| | | namePatchView.btnClick.MouseUpEventHandler += (sender, e) => { |
| | | |
| | | List<string> list = new List<string>(); |
| | | |
| | | for (int i = 0; i < Pir.currPir.FunctioList.Count; i++) |
| | | for (int i = 0; i < PirDevice.Pir.currPir.FunctioList.Count; i++) |
| | | { |
| | | list.Add(Pir.currPir.FunctioList[i].name); |
| | | list.Add(PirDevice.Pir.currPir.FunctioList[i].name); |
| | | } |
| | | Method method = new Method(); |
| | | method.EditControlName(StringId.editName, list, control.name, (name, view) => |
| | |
| | | else |
| | | { |
| | | Method methodError = new Method(); |
| | | methodError.ErrorShow(responsePackNew,""); |
| | | methodError.ErrorShow(responsePackNew, ""); |
| | | } |
| | | |
| | | }); |
| | |
| | | |
| | | }, () => { }); |
| | | }; |
| | | //所属区域 |
| | | View.PatchView quyuPatchView = new View.PatchView(); |
| | | quyuPatchView.frameLayout.Y = namePatchView.frameLayout.Bottom; |
| | | this.AddChidren(quyuPatchView.FLayoutView()); |
| | | quyuPatchView.btnText1.TextID = StringId.suoshuquyu; |
| | | quyuPatchView.btnText2.Text=Intelligence.Automation.LogicMethod.GetGetRoomName(function); |
| | | //所属区域点击事件 |
| | | quyuPatchView.btnClick.MouseUpEventHandler += (sender, e) => |
| | | { |
| | | Method method = new Method(); |
| | |
| | | quyuPatchView.btnText2.Text = Intelligence.Automation.LogicMethod.GetGetRoomName(function); |
| | | }); |
| | | }; |
| | | |
| | | |
| | | //继续添加 |
| | | Button addBtn = new Button |
| | | { |
| | | Y = quyuPatchView.frameLayout.Bottom + Application.GetRealHeight(125), |
| | | X = Application.GetRealWidth(16), |
| | | Width = Application.GetRealWidth(375 - 32), |
| | | Height = Application.GetRealHeight(20), |
| | | TextID = StringId.jixutianjia, |
| | | TextSize = TextSize.text14, |
| | | TextColor = CSS.CSS_Color.textConfirmColor, |
| | | TextAlignment = TextAlignment.Center, |
| | | }; |
| | | this.AddChidren(addBtn); |
| | | //完成 |
| | | View.SaveView saveView = new View.SaveView(); |
| | | this.AddChidren(saveView.FLayoutView()); |
| | | saveView.frameLayout.SetCornerWithSameRadius(Application.GetRealHeight(24), HDLUtils.RectCornerTopLeft | HDLUtils.RectCornerTopRight); |
| | | #endregion |
| | | #region 界面点击事件 |
| | | //遥控器名称点击事件 |
| | | namePatchView.btnClick.MouseUpEventHandler += (sender, e) => { }; |
| | | //所属区域点击事件 |
| | | quyuPatchView.btnClick.MouseUpEventHandler += (sender, e) => { }; |
| | | //继续添加点击事件 |
| | | addBtn.MouseUpEventHandler += (sender, e) => |
| | | { |