| | |
| | | /// 画面显示(底层会固定调用此方法,借以完成画面创建)
|
| | | /// </summary>
|
| | | /// <param name="dicUser">用户的显示文本(key + 文本)</param>
|
| | | /// <param name="nowSelectUser">当前选择的用户</param> |
| | | /// <param name="nowSelectLock">当前选择的开锁方式</param> |
| | | public void ShowForm(Dictionary<string, string> dicUser, List<string> nowSelectUser, List<int> nowSelectLock) |
| | | { |
| | | this.listSelectUser.Clear(); |
| | | /// <param name="nowSelectUser">当前选择的用户</param>
|
| | | /// <param name="nowSelectLock">当前选择的开锁方式</param>
|
| | | public void ShowForm(Dictionary<string, string> dicUser, List<string> nowSelectUser, List<int> nowSelectLock)
|
| | | {
|
| | | this.listSelectUser.Clear();
|
| | | this.listSelectUser.AddRange(nowSelectUser);
|
| | |
|
| | | this.listSelectLock.Clear(); |
| | | this.listSelectLock.Clear();
|
| | | this.listSelectLock.AddRange(nowSelectLock);
|
| | |
|
| | | this.listOldSelectUser.Clear(); |
| | | this.listOldSelectUser.AddRange(nowSelectUser); |
| | | |
| | | this.listOldSelectLock.Clear(); |
| | | this.listOldSelectLock.AddRange(nowSelectLock); |
| | | |
| | | //初始化中部信息 |
| | | this.InitMiddleFrame(dicUser); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 初始化中部信息 |
| | | /// </summary> |
| | | private void InitMiddleFrame(Dictionary<string, string> dicUser) |
| | | this.listOldSelectUser.Clear();
|
| | | this.listOldSelectUser.AddRange(nowSelectUser);
|
| | |
|
| | | this.listOldSelectLock.Clear();
|
| | | this.listOldSelectLock.AddRange(nowSelectLock);
|
| | |
|
| | | //初始化中部信息
|
| | | this.InitMiddleFrame(dicUser);
|
| | | }
|
| | |
|
| | | /// <summary>
|
| | | /// 初始化中部信息
|
| | | /// </summary>
|
| | | private void InitMiddleFrame(Dictionary<string, string> dicUser)
|
| | | {
|
| | | //弧度的圆的一半的高度(固定)
|
| | | int halfRoundHeigth = Application.GetRealHeight(116) / 2; |
| | | //头部高度 |
| | | int halfRoundHeigth = Application.GetRealHeight(116) / 2;
|
| | | //头部高度
|
| | | int topHeight = Application.GetRealHeight(195);
|
| | |
|
| | | //搞一个透明的框
|
| | | var frameTransparent = new FrameLayout();
|
| | | frameTransparent.Y = Application.GetRealHeight(933); |
| | | frameTransparent.Y = Application.GetRealHeight(933);
|
| | | frameTransparent.Height = Application.GetRealHeight(988) + halfRoundHeigth * 2;//高度就是要它超过,随便搞的
|
| | | frameTransparent.BackgroundColor = UserCenterColor.Current.Transparent; |
| | | frameTransparent.BackgroundColor = UserCenterColor.Current.Transparent;
|
| | | bodyFrameLayout.AddChidren(frameTransparent);
|
| | |
|
| | | //明细列表的桌布,白色背景(它与实际高度小了半个弧度的圆)
|
| | | var detailBackFrame = new FrameLayout(); |
| | | detailBackFrame.Y = halfRoundHeigth; |
| | | var detailBackFrame = new FrameLayout();
|
| | | detailBackFrame.Y = halfRoundHeigth;
|
| | | detailBackFrame.Height = frameTransparent.Height;
|
| | | detailBackFrame.BackgroundColor = UserCenterColor.Current.White; |
| | | detailBackFrame.BackgroundColor = UserCenterColor.Current.White;
|
| | | frameTransparent.AddChidren(detailBackFrame);
|
| | |
|
| | | //弧度的圆
|
| | | var rowRound = new FrameLayout(); |
| | | rowRound.Width = bodyFrameLayout.Width; |
| | | rowRound.Height = halfRoundHeigth * 2; |
| | | rowRound.BackgroundColor = UserCenterColor.Current.White; |
| | | rowRound.Radius = (uint)halfRoundHeigth; |
| | | frameTransparent.AddChidren(rowRound); |
| | | |
| | | var rowRound = new FrameLayout();
|
| | | rowRound.Width = bodyFrameLayout.Width;
|
| | | rowRound.Height = halfRoundHeigth * 2;
|
| | | rowRound.BackgroundColor = UserCenterColor.Current.White;
|
| | | rowRound.Radius = (uint)halfRoundHeigth;
|
| | | frameTransparent.AddChidren(rowRound);
|
| | |
|
| | | //类型筛选
|
| | | var btnTitle = new NormalViewControl(detailBackFrame.Width, Application.GetRealHeight(63), false); |
| | | btnTitle.Y = Application.GetRealHeight(35); |
| | | btnTitle.TextID = R.MyInternationalizationString.uScreeningType; |
| | | btnTitle.TextColor = UserCenterColor.Current.TextColor4; |
| | | btnTitle.TextSize = 16; |
| | | btnTitle.TextAlignment = TextAlignment.Center; |
| | | rowRound.AddChidren(btnTitle); |
| | | |
| | | //重置 |
| | | var btnReset = new NormalViewControl(200, 58, true); |
| | | btnReset.X = Application.GetRealWidth(81); |
| | | btnReset.Y = Application.GetRealHeight(40); |
| | | btnReset.TextColor = UserCenterColor.Current.TextGrayColor1; |
| | | btnReset.TextID = R.MyInternationalizationString.uResettion; |
| | | rowRound.AddChidren(btnReset); |
| | | var btnTitle = new NormalViewControl(detailBackFrame.Width, Application.GetRealHeight(63), false);
|
| | | btnTitle.Y = Application.GetRealHeight(35);
|
| | | btnTitle.TextID = R.MyInternationalizationString.uScreeningType;
|
| | | btnTitle.TextColor = UserCenterColor.Current.TextColor4;
|
| | | btnTitle.TextSize = 16;
|
| | | btnTitle.TextAlignment = TextAlignment.Center;
|
| | | rowRound.AddChidren(btnTitle);
|
| | |
|
| | | //重置
|
| | | var btnReset = new NormalViewControl(200, 58, true);
|
| | | btnReset.X = Application.GetRealWidth(81);
|
| | | btnReset.Y = Application.GetRealHeight(40);
|
| | | btnReset.TextColor = UserCenterColor.Current.TextGrayColor1;
|
| | | btnReset.TextID = R.MyInternationalizationString.uResettion;
|
| | | rowRound.AddChidren(btnReset);
|
| | | btnReset.ButtonClickEvent += (sender, e) =>
|
| | | {
|
| | | detailBackFrame.RemoveAll();
|
| | |
| | | };
|
| | |
|
| | | //确定
|
| | | var btnFinish = new NormalViewControl(200, 58, true); |
| | | btnFinish.X = Application.GetRealWidth(800); |
| | | btnFinish.Y = Application.GetRealHeight(40); |
| | | btnFinish.TextAlignment = TextAlignment.CenterRight; |
| | | btnFinish.TextColor = 0xfffb744a; |
| | | btnFinish.TextID = R.MyInternationalizationString.uConfirm1; |
| | | rowRound.AddChidren(btnFinish); |
| | | var btnFinish = new NormalViewControl(200, 58, true);
|
| | | btnFinish.X = Application.GetRealWidth(800);
|
| | | btnFinish.Y = Application.GetRealHeight(40);
|
| | | btnFinish.TextAlignment = TextAlignment.CenterRight;
|
| | | btnFinish.TextColor = 0xfffb744a;
|
| | | btnFinish.TextID = R.MyInternationalizationString.uConfirm1;
|
| | | rowRound.AddChidren(btnFinish);
|
| | | btnFinish.ButtonClickEvent += (sender, e) =>
|
| | | {
|
| | | FinishSelectEvent?.Invoke(listSelectUser, listSelectLock);
|
| | |
| | | //线
|
| | | var btnLine = new NormalViewControl(detailBackFrame.Width, ControlCommonResourse.BottomLineHeight, false);
|
| | | btnLine.Y = Application.GetRealHeight(138) - ControlCommonResourse.BottomLineHeight - halfRoundHeigth;
|
| | | btnLine.BackgroundColor = UserCenterColor.Current.ButtomLine; |
| | | btnLine.BackgroundColor = UserCenterColor.Current.ButtomLine;
|
| | | detailBackFrame.AddChidren(btnLine);
|
| | |
|
| | | //初始化选择用户控件
|
| | |
| | | this.InitUnLockSelectControl(detailBackFrame, btnLine.Bottom);
|
| | |
|
| | | //动画效果
|
| | | frameTransparent.Animate = Animate.DownToUp; |
| | | frameTransparent.Animate = Animate.DownToUp;
|
| | | }
|
| | |
|
| | | #endregion
|
| | |
| | | var btnLine = new NormalViewControl(Application.GetRealWidth(919), ControlCommonResourse.BottomLineHeight, false);
|
| | | btnLine.Gravity = Gravity.CenterHorizontal;
|
| | | btnLine.Y = YY + Application.GetRealHeight(386);
|
| | | btnLine.BackgroundColor = UserCenterColor.Current.ButtomLine; |
| | | btnLine.BackgroundColor = UserCenterColor.Current.ButtomLine;
|
| | | detailBackFrame.AddChidren(btnLine);
|
| | | }
|
| | |
|
| | |
| | | /// <summary>
|
| | | /// 界面关闭
|
| | | /// </summary>
|
| | | public override void CloseForm()
|
| | | public override void CloseFormBefore()
|
| | | {
|
| | | this.FinishSelectEvent = null;
|
| | |
|
| | | base.CloseForm();
|
| | | base.CloseFormBefore();
|
| | | }
|
| | |
|
| | | #endregion
|