From 8df24b0a3dfd5b6f39c5393ef24eab25b70ab858 Mon Sep 17 00:00:00 2001 From: wxr <464027401@qq.com> Date: 星期五, 11 九月 2020 13:18:33 +0800 Subject: [PATCH] 202009111 --- HDL_ON/UI/UI0-Public/PublicAssmebly.cs | 44 ++++++++++++++++++++++++++------------------ 1 files changed, 26 insertions(+), 18 deletions(-) diff --git a/HDL_ON/UI/UI0-Public/PublicAssmebly.cs b/HDL_ON/UI/UI0-Public/PublicAssmebly.cs index a275263..0b0a36d 100644 --- a/HDL_ON/UI/UI0-Public/PublicAssmebly.cs +++ b/HDL_ON/UI/UI0-Public/PublicAssmebly.cs @@ -130,6 +130,10 @@ if (etParater.Text.Length > 20) { etParater.Text = etParater.Text.Remove(20); + +#if __ANDROID__ + etParater.SetSelectionEnd(); +#endif } }; @@ -173,7 +177,7 @@ Height = Application.GetRealHeight(43 + 1), TextAlignment = TextAlignment.Center, //TextColor = CSS_Color.TextualColor, - //TextSize = CSS_FontSize.SubheadingFontSize, + TextSize = CSS_FontSize.SubheadingFontSize, TextColor = CSS_Color.MainBackgroundColor, BackgroundColor = CSS_Color.MainColor, TextID = StringId.Confirm, @@ -272,22 +276,12 @@ }; contentView.AddChidren(btnCancel); - //Button btnBottomLine = new Button() - //{ - // X = btnCancel.Right, - // Y = btnLine.Bottom, - // Height = Application.GetRealHeight(43), - // Width = Application.GetRealWidth(1), - // BackgroundColor = CSS_Color.DividingLineColor, - //}; - //contentView.AddChidren(btnBottomLine); - Button btnConfirm = new Button() { X = btnCancel.Right, Y = btnLine.Y, Width = Application.GetRealWidth(135), - Height = Application.GetRealHeight(43 + 1), + Height = Application.GetRealHeight(45), TextAlignment = TextAlignment.Center, //TextColor = CSS_Color.TextualColor, TextSize = CSS_FontSize.SubheadingFontSize, @@ -330,20 +324,31 @@ /// <param name="isWhite"></param> public void TipMsgAutoClose(string msg, bool isWhite, int closeTime = 1500) { - Dialog dialog = new Dialog() + Dialog dialog = new Dialog(); + + FrameLayout dialogBody = new FrameLayout(); + dialog.AddChidren(dialogBody); + dialogBody.MouseUpEventHandler = (sender, e) => + { + dialog.Close(); + dialog = null; + }; + + FrameLayout frame = new FrameLayout() { X = Application.GetRealWidth(89), Y = Application.GetRealHeight(285), Width = Application.GetRealWidth(198), Height = Application.GetRealHeight(98), - }; - - FrameLayout frame = new FrameLayout() - { BackgroundColor = isWhite ? 0xE6FFFFFF : CSS_Color.DialogTransparentColor1, Radius = (uint)Application.GetRealWidth(12), }; dialog.AddChidren(frame); + frame.MouseUpEventHandler = (sender, e) => + { + dialog.Close(); + dialog = null; + }; Button btnTipIcon = new Button() { @@ -373,7 +378,10 @@ Thread.Sleep(closeTime); Application.RunOnMainThread(() => { - dialog.Close(); + if(dialog!=null) + { + dialog.Close(); + } }); }) { IsBackground = true }.Start(); -- Gitblit v1.8.0