From af0266fa5570b6adcdb22f631bf13170e8646ca5 Mon Sep 17 00:00:00 2001 From: gxc <guoxuecheng@guoxuechengdeMacBook-Pro.local> Date: 星期一, 28 十月 2019 14:15:21 +0800 Subject: [PATCH] Merge branch 'dev-tzy' into DEV_GXC --- ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WiredGatewayDirectionForm.cs | 87 +++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 87 insertions(+), 0 deletions(-) diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WiredGatewayDirectionForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WiredGatewayDirectionForm.cs new file mode 100755 index 0000000..22ab884 --- /dev/null +++ b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WiredGatewayDirectionForm.cs @@ -0,0 +1,87 @@ +锘縰sing System; +namespace Shared.Phone.UserCenter.GatewayAdd +{ + /// <summary> + /// 娣诲姞鏈夌嚎缃戝叧鐨勬寚绀哄浘鐢婚潰 + /// </summary> + public class WiredGatewayDirectionForm : EditorCommonForm + { + /// <summary> + /// 鐢婚潰鏄剧ず(搴曞眰浼氬浐瀹氳皟鐢ㄦ鏂规硶锛屽�熶互瀹屾垚鐢婚潰鍒涘缓) + /// </summary> + public void ShowForm() + { + //璁剧疆鏍囬淇℃伅 + base.SetTitleText(Language.StringByID(R.MyInternationalizationString.uAddWiredGateway)); + + //鍒濆鍖栦腑閮ㄦ帶浠� + this.InitMiddleFrame(); + } + + /// <summary> + /// 鍒濆鍖栦腑閮ㄦ帶浠� + /// </summary> + private void InitMiddleFrame() + { + //娓呯┖bodyFrame + this.ClearBodyFrame(); + + //鍥炬爣 + var btnimage = new PicViewControl(533, 884, true); + btnimage.Y = Application.GetRealHeight(173); + btnimage.Gravity = Gravity.CenterHorizontal; + btnimage.UnSelectedImagePath = "Gateway/WiredGatewayInstruct.png"; + bodyFrameLayout.AddChidren(btnimage); + + //璇风‘淇濈綉鍏充笌缃戠嚎杩炴帴{0}绯荤粺鐏瘡绉掗棯鐑佷竴娆� + string[] strMsg = Language.StringByID(R.MyInternationalizationString.ConfirmLineConnectMsg).Split(new string[] { "{0}" }, StringSplitOptions.RemoveEmptyEntries); + var btnMsg1 = new NormalViewControl(bodyFrameLayout.Width, Application.GetRealHeight(60), false); + btnMsg1.TextColor = UserCenterColor.Current.TextGrayColor3; + btnMsg1.TextAlignment = TextAlignment.Center; + btnMsg1.Text = strMsg[0]; + btnMsg1.Y = btnimage.Bottom + Application.GetRealHeight(101); + bodyFrameLayout.AddChidren(btnMsg1); + if (strMsg.Length > 1) + { + var btnMsg2= new NormalViewControl(bodyFrameLayout.Width, Application.GetRealHeight(60), false); + btnMsg2.TextColor = UserCenterColor.Current.TextGrayColor3; + btnMsg2.TextAlignment = TextAlignment.Center; + btnMsg2.Text = strMsg[1]; + btnMsg2.Y = btnMsg1.Bottom; + bodyFrameLayout.AddChidren(btnMsg2); + } + + //鏌ョ湅甯姪 + var btnHelp = new NormalViewControl(bodyFrameLayout.Width, Application.GetRealHeight(49), false); + btnHelp.Y = Application.GetRealHeight(1388); + btnHelp.TextSize = 12; + btnHelp.TextAlignment = TextAlignment.Center; + btnHelp.TextColor = UserCenterColor.Current.TextOrangeColor; + btnHelp.Text = Language.StringByID(R.MyInternationalizationString.uSearchHelp); + btnHelp.ButtonClickEvent += (sender, e) => + { + var form = new DeviceDirection.DeviceDirectionHelpForm(); + form.AddForm("Gateway"); + }; + bodyFrameLayout.AddChidren(btnHelp); + //搴曠嚎 + int lineWidth = btnHelp.GetRealWidthByText(12); + var btnLine = new NormalViewControl(lineWidth, ControlCommonResourse.BottomLineHeight, false); + btnLine.BackgroundColor = UserCenterColor.Current.TextOrangeColor; + btnLine.Gravity = Gravity.CenterHorizontal; + btnLine.Y = btnHelp.Bottom - Application.GetRealHeight(8); + bodyFrameLayout.AddChidren(btnLine); + + //涓嬩竴姝� + var btnNext = new BottomClickButton(); + btnNext.TextID = R.MyInternationalizationString.uNextway; + bodyFrameLayout.AddChidren(btnNext); + + btnNext.MouseUpEventHandler += (sender, e) => + { + var form = new WiredGatewaySearchForm(); + this.AddFromAndRemoveNowForm(form); + }; + } + } +} -- Gitblit v1.8.0