From 37c315988c2dc11e4f477233f7a9f87d57bb61aa Mon Sep 17 00:00:00 2001 From: wei <kaede@kaededeMacBook-Air.local> Date: 星期一, 08 三月 2021 09:17:15 +0800 Subject: [PATCH] 数据结构优化修改 --- HDL_ON/UI/UI2/FuntionControlView/Electrical/TVPage.cs | 17 +++++++++-------- 1 files changed, 9 insertions(+), 8 deletions(-) diff --git a/HDL_ON/UI/UI2/FuntionControlView/Electrical/TVPage.cs b/HDL_ON/UI/UI2/FuntionControlView/Electrical/TVPage.cs index 737c59b..b9bc1a6 100644 --- a/HDL_ON/UI/UI2/FuntionControlView/Electrical/TVPage.cs +++ b/HDL_ON/UI/UI2/FuntionControlView/Electrical/TVPage.cs @@ -43,7 +43,8 @@ #endregion #region 鍖哄煙鍙橀噺 - TV tv; + TV tvTemp = new TV(); + Function function; Button btnCollection_Out; Button btnFunctionName_Out; Button btnFromFloor_Out; @@ -56,7 +57,7 @@ public TVPage(Function func) { bodyView = this; - tv = func as TV; + function = func; } @@ -86,7 +87,7 @@ TextColor = CSS_Color.FirstLevelTitleColor, TextAlignment = TextAlignment.CenterLeft, TextSize = CSS_FontSize.EmphasisFontSize_FirstLevel, - Text = tv.name, + Text = function.name, }; controlView.AddChidren(btnFunctionName); @@ -99,7 +100,7 @@ TextColor = CSS_Color.PromptingColor1, TextAlignment = TextAlignment.CenterLeft, TextSize = CSS_FontSize.PromptFontSize_FirstLevel, - Text = tv.GetRoomListName() + Text = function.GetRoomListName() }; controlView.AddChidren(btnFromFoorAndRoom); @@ -111,7 +112,7 @@ Height = Application.GetMinRealAverage(40), SelectedImagePath = "Collection/CollectionIcon.png", UnSelectedImagePath = "Collection/CollectionGrayIcon.png", - IsSelected = tv.collect + IsSelected = function.collect }; //controlView.AddChidren(btnCollection); //2020-12-16 濡傛灉鏄垚鍛橀殣钘忔敹钘忓姛鑳� @@ -335,8 +336,8 @@ LoadEventList(); - new TopViewDiv(bodyView, Language.StringByID(StringId.TV)).LoadTopView_FunctionTop(tv, actionRefresh); - DriverLayer.Control.Ins.SendReadCommand(tv); + new TopViewDiv(bodyView, Language.StringByID(StringId.TV)).LoadTopView_FunctionTop(function, actionRefresh); + DriverLayer.Control.Ins.SendReadCommand(function); } @@ -420,7 +421,7 @@ numberView.AddChidren(btn); btn.MouseUpEventHandler = (sender, e) => { btn.IsSelected = false; - tv.ControlTV(i); + tvTemp.ControlTV(i,function); }; btn.MouseDownEventHandler = (sender, e) => { btn.IsSelected = true; -- Gitblit v1.8.0