| | |
| | | /// </summary>
|
| | | public void Show()
|
| | | {
|
| | | if (myTip != null)
|
| | | try
|
| | | {
|
| | | myTip.Show(Common.CommonPage.Instance);
|
| | | myTip = null;
|
| | | return;
|
| | | if (myTip != null)
|
| | | {
|
| | | myTip.Show(Common.CommonPage.Instance);
|
| | | myTip = null;
|
| | | return;
|
| | | }
|
| | | //初始化控件
|
| | | this.InitMsgControl();
|
| | | }
|
| | |
|
| | | //初始化控件
|
| | | this.InitMsgControl();
|
| | | catch (Exception ex) { HdlLogLogic.Current.WriteLog(ex); }
|
| | | }
|
| | |
|
| | | #endregion
|
| | |
| | | /// </summary>
|
| | | private void InitMsgControl()
|
| | | {
|
| | | //添加界面
|
| | | var nowForm = UserView.HomePage.Instance.GetChildren(UserView.HomePage.Instance.ChildrenCount - 1);
|
| | | if (nowForm == null || (nowForm is ViewGroup) == false)
|
| | | {
|
| | | return;
|
| | | }
|
| | | //主控件
|
| | | var frameMain = new FrameLayout();
|
| | | frameMain.BackgroundColor = UserCenterColor.Current.DialogBackColor;
|
| | | ((ViewGroup)nowForm).AddChidren(frameMain);
|
| | | Common.CommonPage.Instance.AddChidren(frameMain);
|
| | | frameMain.MouseUpEventHandler += (sender, e) =>
|
| | | {
|
| | | //移除界面
|
| | | frameMain.RemoveFromParent();
|
| | | this.ConfirmClickEvent = null;
|
| | | };
|
| | |
|
| | | //白色背景框
|
| | | var frameBack = new FrameLayout();
|
| | |
| | | frameBack.BackgroundColor = UserCenterColor.Current.White;
|
| | | frameBack.Y = Application.GetRealHeight(706);
|
| | | frameBack.Gravity = Gravity.CenterHorizontal;
|
| | | frameBack.Radius = 8;
|
| | | frameBack.Radius = (uint)Application.GetRealHeight(17);
|
| | | frameMain.AddChidren(frameBack);
|
| | | //标题
|
| | | var btnTitle = new NormalViewControl(frameBack.Width, Application.GetRealHeight(65), false);
|
| | |
| | | else if (msgType == ShowMsgType.Confirm)
|
| | | {
|
| | | btnTitle.TextID = R.MyInternationalizationString.NormalTip;
|
| | | }
|
| | | else if (msgType == ShowMsgType.Remind)
|
| | | {
|
| | | btnTitle.TextID = R.MyInternationalizationString.uRemind;
|
| | | }
|
| | |
|
| | | //消息
|
| | |
| | | frameConfirm.Height = Application.GetRealHeight(127);
|
| | | frameConfirm.Width = frameBack.Width;
|
| | | frameConfirm.Gravity = Gravity.BottomCenter;
|
| | | frameConfirm.Radius = 8;
|
| | | frameConfirm.RadiusEx = 17;
|
| | | frameConfirm.BackgroundColor = UserCenterColor.Current.ClickButtonDefultColor;
|
| | | frameBack.AddChidren(frameConfirm);
|
| | | //把上圆角覆盖为方角
|