From 1f6f024bddf48dea1c17c54ade1535a10ef7b39b Mon Sep 17 00:00:00 2001 From: WJC <wjc@hdlchina.com.cn> Date: 星期一, 23 三月 2020 17:16:37 +0800 Subject: [PATCH] 2020-03-23-2 --- ZigbeeApp/Shared/Phone/Device/Category/Category.cs | 42 ++++++++++++++++++++++-------------------- 1 files changed, 22 insertions(+), 20 deletions(-) diff --git a/ZigbeeApp/Shared/Phone/Device/Category/Category.cs b/ZigbeeApp/Shared/Phone/Device/Category/Category.cs index 8c0803a..32de9d4 100644 --- a/ZigbeeApp/Shared/Phone/Device/Category/Category.cs +++ b/ZigbeeApp/Shared/Phone/Device/Category/Category.cs @@ -17,7 +17,6 @@ /// </summary> public class Category : FrameLayout, ZigBee.Common.IStatus { - #region 鈼� 鍙橀噺____________________________ /// <summary> /// The instance. @@ -2113,8 +2112,8 @@ //鎺ㄨ崘妯℃澘寮�鍏虫帶浠� var recommendswitchBtn = new Button { - Width = Application.GetMinRealAverage(104), - Height = Application.GetMinRealAverage(63), + Width = Application.GetRealWidth(104), + Height = Application.GetRealHeight(63), UnSelectedImagePath = "ZigeeLogic/logicclose.png", SelectedImagePath = "ZigeeLogic/logicopen.png", X = bjFrameLayout.Width - Application.GetRealWidth(104 + 58), @@ -2335,9 +2334,16 @@ refresview.BackgroundColor = ZigbeeColor.Current.LogicBackgroundColor; } } + foreach (var logic in Common.Logic.LogicList) { - + var fLayout = new FrameLayout + { + Height = Application.GetRealHeight(190 + 30), + Width = Application.GetRealWidth(1080 - 58), + BackgroundColor = ZigbeeColor.Current.LogicBackgroundColor, + }; + refresview.AddChidren(fLayout); var logicRowlayout = new RowLayout { @@ -2345,11 +2351,10 @@ Width = Application.GetRealWidth(1080 - 58), LineColor = ZigbeeColor.Current.LogicBackgroundColor, BackgroundColor = ZigbeeColor.Current.LogicBackgroundColor, + SubViewWidth = Application.GetRealWidth(184),//鏀瑰彉缂栬緫鎺т欢瀹藉害澶氬皯锛� }; - refresview.AddChidren(logicRowlayout); - - + fLayout.AddChidren(logicRowlayout); var logicnameBtn = new Button { @@ -2364,7 +2369,6 @@ }; logicRowlayout.AddChidren(logicnameBtn); - var logicswitchBtn = new Button { Width = Application.GetMinRealAverage(104), @@ -2373,10 +2377,9 @@ SelectedImagePath = "ZigeeLogic/logicopen.png", X = logicRowlayout.Width - Application.GetRealWidth(104 + 58), Y = Application.GetRealHeight(58 + 30 + 9 + 30), + }; logicRowlayout.AddChidren(logicswitchBtn); - - logicswitchBtn.MouseUpEventHandler += (sender1, e1) => { @@ -2424,7 +2427,6 @@ }; - ///鍒犻櫎 var del = new Button { @@ -2451,13 +2453,13 @@ }; var line = new Button { - Y = Application.GetRealHeight(215), - Height = Application.GetRealHeight(5), + Y = fLayout.Height-1, + Height =1, + X = Application.GetRealWidth(58), Width = Application.GetRealWidth(1080 - 58), BackgroundColor = ZigbeeColor.Current.LogicRowLayoutLineColor, - X = Application.GetRealWidth(58), }; - logicRowlayout.AddChidren(line); + fLayout.AddChidren(line); } } @@ -2517,19 +2519,19 @@ var iconindex = iconIndexlist[i]; var typebjBtn = new FrameLayout { - Width = Application.GetRealWidth(82), - Height = Application.GetRealHeight(82), + Width = Application.GetMinRealAverage(82), + Height = Application.GetMinRealAverage(82), X = Application.GetRealWidth(58) + Application.GetRealWidth(12 + (12 + 82 + 45 + 12) * i), Y = Application.GetRealHeight(58 + 30 + 30), - Radius = (uint)Application.GetRealHeight(41), + Radius = (uint)Application.GetMinRealAverage(41), BackgroundColor = ZigbeeColor.Current.LogicMiddleBackgroundColor, }; logicRowlayout.AddChidren(typebjBtn); var typeIconBtn = new Button { - Width = Application.GetRealWidth(58), - Height = Application.GetRealHeight(58), + Width = Application.GetMinRealAverage(58), + Height = Application.GetMinRealAverage(58), Gravity = Gravity.Center, }; -- Gitblit v1.8.0