From d78515ac4ac8cf4a1785d9df18058d6724f12b79 Mon Sep 17 00:00:00 2001 From: 黄学彪 <hxb@hdlchina.com.cn> Date: 星期四, 14 一月 2021 19:34:59 +0800 Subject: [PATCH] 合并xm2021-01-13 wjc2021-02-06 --- ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/MiniGatewayDirection3Form.cs | 119 +++++++++++++++++++++++++++++++++++++++++------------------ 1 files changed, 82 insertions(+), 37 deletions(-) diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/MiniGatewayDirection3Form.cs b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/MiniGatewayDirection3Form.cs index 5acc2e1..6b33c67 100755 --- a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/MiniGatewayDirection3Form.cs +++ b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/MiniGatewayDirection3Form.cs @@ -35,14 +35,6 @@ //娓呯┖bodyFrame this.ClearBodyFrame(); - //鏌ョ湅甯姪 - var btnHelp = this.AddHelpControl(); - btnHelp.ButtonClickEvent += (sender, e) => - { - var form = new AddGatewayHelpForm(); - form.AddForm("Mini"); - }; - //涓嬩竴姝� var btnNext = new BottomClickButton(); btnNext.TextID = R.MyInternationalizationString.uNextway; @@ -71,40 +63,93 @@ framePic.BackgroundImagePath = "Gateway/MiniGatewaySearching.png"; bodyFrameLayout.AddChidren(framePic); - //鎵嬫満鍘昏缃繛鎺ヨ矾鐢卞櫒 - string[] ArryMsg = Language.StringByID(R.MyInternationalizationString.uAddApWirelessGatewayMsg3).Split(new string[] { "{0}" }, StringSplitOptions.RemoveEmptyEntries); - int yy = framePic.Bottom + Application.GetRealHeight(369); - foreach (var msg in ArryMsg) + //缃戝叧杩炴帴璺敱鍣� + var btnTitle = new NormalViewControl(400, 60, true); + btnTitle.TextID = R.MyInternationalizationString.uGatewayConnectionRouter; + btnTitle.X = Application.GetRealWidth(75); + btnTitle.Y = framePic.Bottom + Application.GetRealHeight(107); + btnTitle.IsBold = true; + btnTitle.TextSize = 14; + bodyFrameLayout.AddChidren(btnTitle); + + //1.缃戝叧鎺ユ敹璺敱鍣ㄨ处鍙峰拰瀵嗙爜鎴愬姛 + //2.绯荤粺閲嶅惎(缁跨伅闂儊50绉�) + //3.杩炴帴灞�鍩熺綉鎴愬姛(钃濈伅1绉掑懆鏈熼棯鐑�) + //4.鐐瑰嚮"{1}"瀹屾垚鎵嬫満杩炴帴瀹跺涵WIFI + //5.鐐瑰嚮涓嬩竴姝� + string[] ArryMsg = Language.StringByID(R.MyInternationalizationString.uAddMiniGatewayMsg3).Split(new string[] { "{0}" }, StringSplitOptions.RemoveEmptyEntries); + int yy = btnTitle.Bottom + Application.GetRealHeight(23); + for (int i = 0; i < ArryMsg.Length; i++) { - var btnMsg = new NormalViewControl(bodyFrameLayout.Width, Application.GetRealHeight(60), false); - btnMsg.Text = msg; - btnMsg.Y = yy; - btnMsg.TextAlignment = TextAlignment.Center; - btnMsg.TextColor = UserCenterColor.Current.TextGrayColor3; - bodyFrameLayout.AddChidren(btnMsg); - yy = btnMsg.Bottom; + if (i != 3) + { + var btnMsg = new NormalViewControl(bodyFrameLayout.Width, Application.GetRealHeight(60), false); + btnMsg.Text = ArryMsg[i]; + btnMsg.Y = yy; + btnMsg.X = btnTitle.X; + btnMsg.TextColor = UserCenterColor.Current.TextGrayColor1; + btnMsg.TextSize = 12; + bodyFrameLayout.AddChidren(btnMsg); + yy = btnMsg.Bottom; + } + else + { + //3.鐐瑰嚮"{1}"瀹屾垚鎵嬫満杩炴帴瀹跺涵WIFI + var myArry = ArryMsg[i].Split(new string[] { "{1}" }, StringSplitOptions.RemoveEmptyEntries); + //3.鐐瑰嚮 + var btnMsg1 = new NormalViewControl(bodyFrameLayout.Width, Application.GetRealHeight(60), false); + btnMsg1.Text = myArry[0]; + btnMsg1.Y = yy; + btnMsg1.X = btnTitle.X; + btnMsg1.TextColor = UserCenterColor.Current.TextGrayColor1; + btnMsg1.TextSize = 12; + btnMsg1.Width = btnMsg1.GetRealWidthByText(); + bodyFrameLayout.AddChidren(btnMsg1); + + //鍘昏缃� + var btnSettion = new NormalViewControl(bodyFrameLayout.Width, Application.GetRealHeight(60), false); + btnSettion.X = btnMsg1.Right; + btnSettion.Y = btnMsg1.Y; + btnSettion.TextSize = 12; + btnSettion.TextAlignment = TextAlignment.Center; + btnSettion.TextColor = 0xff0075ff; + btnSettion.Text = Language.StringByID(R.MyInternationalizationString.uGotoSettion); + btnSettion.Width = btnSettion.GetRealWidthByText(); + bodyFrameLayout.AddChidren(btnSettion); + btnSettion.ButtonClickEvent += (sender, e) => + { + HdlWifiLogic.Current.OpenAppWifiSettion(); + btnNext.Visible = true; + }; + //搴曠嚎 + var btnLine1 = new NormalViewControl(btnSettion.Width, ControlCommonResourse.BottomLineHeight, false); + btnLine1.BackgroundColor = 0xff0075ff; + btnLine1.X = btnSettion.X; + btnLine1.Y = btnSettion.Bottom - Application.GetRealHeight(8); + bodyFrameLayout.AddChidren(btnLine1); + + //瀹屾垚鎵嬫満杩炴帴瀹跺涵WIFI + var btnMsg2 = new NormalViewControl(bodyFrameLayout.Width, Application.GetRealHeight(60), false); + btnMsg2.Text = myArry[1]; + btnMsg2.Y = btnMsg1.Y; + btnMsg2.X = btnSettion.Right; + btnMsg2.TextColor = UserCenterColor.Current.TextGrayColor1; + btnMsg2.TextSize = 12; + btnMsg2.Width = btnMsg2.GetRealWidthByText(); + bodyFrameLayout.AddChidren(btnMsg2); + + yy = btnMsg1.Bottom; + } + } - //鍘昏缃� - var btnSettion = new NormalViewControl(bodyFrameLayout.Width, Application.GetRealHeight(50), false); - btnSettion.Y = yy + Application.GetRealHeight(12); - btnSettion.TextSize = 12; - btnSettion.TextAlignment = TextAlignment.Center; - btnSettion.TextColor = 0xff0075ff; - btnSettion.Text = Language.StringByID(R.MyInternationalizationString.uGotoSettion); - btnSettion.ButtonClickEvent += (sender, e) => + //鏌ョ湅甯姪 + var btnHelp = this.AddHelpControl(); + btnHelp.ButtonClickEvent += (sender, e) => { - HdlWifiLogic.Current.OpenAppWifiSettion(); - btnNext.Visible = true; + var form = new AddGatewayHelpForm(); + form.AddForm("Mini"); }; - bodyFrameLayout.AddChidren(btnSettion); - //搴曠嚎 - int lineWidth = btnSettion.GetRealWidthByText(); - var btnLine1 = new NormalViewControl(lineWidth, ControlCommonResourse.BottomLineHeight, false); - btnLine1.BackgroundColor = 0xff0075ff; - btnLine1.Gravity = Gravity.CenterHorizontal; - btnLine1.Y = btnSettion.Bottom - Application.GetRealHeight(8); - bodyFrameLayout.AddChidren(btnLine1); } #endregion -- Gitblit v1.8.0