From ff3cfcf62632bf43e51a6b6098c203bf0f5cddbc Mon Sep 17 00:00:00 2001 From: gxc <guoxuecheng@guoxuechengdeMacBook-Pro.local> Date: 星期二, 24 十二月 2019 19:53:29 +0800 Subject: [PATCH] 2019.12.24 --- ZigbeeApp/Shared/Phone/UserCenter/UserMain/UserMainForm.cs | 37 +++++++++++++++++++++++++++---------- 1 files changed, 27 insertions(+), 10 deletions(-) diff --git a/ZigbeeApp/Shared/Phone/UserCenter/UserMain/UserMainForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/UserMain/UserMainForm.cs index fc53b31..a6f1f12 100755 --- a/ZigbeeApp/Shared/Phone/UserCenter/UserMain/UserMainForm.cs +++ b/ZigbeeApp/Shared/Phone/UserCenter/UserMain/UserMainForm.cs @@ -25,11 +25,15 @@ /// <summary> /// 鐢ㄦ埛澶村儚 /// </summary> - private IconViewControl btnUserIcon = null; + private ImageView btnUserIcon = null; /// <summary> /// 鐨囧啝 /// </summary> private IconViewControl btnImperialCrown = null; + /// <summary> + /// 淇℃伅鎻愮ず鎺т欢 + /// </summary> + private MessageManagementControl msgControl = null; #endregion @@ -67,6 +71,12 @@ //娓呯┖bodyFrame this.ClearBodyFrame(); + //淇℃伅鎻愮ず鎺т欢 + this.msgControl = new MessageManagementControl(); + msgControl.Y = Application.GetRealHeight(127); + msgControl.X = Application.GetRealWidth(953); + bodyFrameLayout.AddChidren(this.msgControl); + //涓汉涓績 var btnTitle = new NormalViewControl(350, 100, true); btnTitle.X = ControlCommonResourse.XXLeft; @@ -81,7 +91,7 @@ frameBack.BackgroundColor = UserCenterColor.Current.BodyFrameLayout; frameBack.Y = Application.GetRealHeight(380); frameBack.Gravity = Gravity.CenterHorizontal; - frameBack.Radius = (uint)Application.GetMinRealAverage(12); + frameBack.Radius = 12; frameBack.Width = bodyFrameLayout.Width - Application.GetRealWidth(29 * 2); frameBack.Height = bodyFrameLayout.Height - Application.GetRealHeight(380) + Application.GetRealHeight(100); bodyFrameLayout.AddChidren(frameBack); @@ -107,9 +117,12 @@ private void InitUserInfoControl(FrameLayout frameWhite) { //鐢ㄦ埛澶村儚 - this.btnUserIcon = new IconViewControl(280); + this.btnUserIcon = new ImageView(); + btnUserIcon.Height = Application.GetMinRealAverage(280); + btnUserIcon.Width = Application.GetMinRealAverage(280); + btnUserIcon.Radius = (uint)Application.GetMinRealAverage(280) / 2; btnUserIcon.X = Application.GetRealWidth(121); - btnUserIcon.UnSelectedImagePath = UserCenterResourse.UserInfo.UserIconFile; + btnUserIcon.ImageBytes = Shared.IO.FileUtils.ReadFile(UserCenterResourse.UserInfo.UserIconFile); bodyFrameLayout.AddChidren(btnUserIcon); btnUserIcon.Y = frameWhite.Y - Application.GetRealHeight(109); btnUserIcon.MouseUpEventHandler += (sender, e) => @@ -173,7 +186,7 @@ frameWhiteBack.Gravity = Gravity.CenterHorizontal; frameWhiteBack.Height = Application.GetRealHeight(371); frameWhiteBack.Width = frameWhite.Width - Application.GetRealWidth(29 * 2); - frameWhiteBack.Radius = (uint)Application.GetMinRealAverage(10); + frameWhiteBack.Radius = 10; frameWhiteBack.BackgroundColor = UserCenterColor.Current.White; frameWhite.AddChidren(frameWhiteBack); } @@ -352,7 +365,7 @@ btnBackView.X -= ControlCommonResourse.XXLeft / 2; rowback.ButtonClickEvent += (sender, e) => { - var form = new HdlBackup.HdlBackupMenuForm(); + var form = new HdlBackup.HdlBackupListForm(); form.AddForm(); }; } @@ -375,8 +388,8 @@ btnSuView.X -= ControlCommonResourse.XXLeft / 2; rowSuggestion.ButtonClickEvent += (sender, e) => { - var form = new DeviceDoorLock.DoorLockHistoryLogForm(); - form.AddForm("澶╀笅绗竴"); + var form = new Suggestion.FeedbackForm(); + form.AddForm(); }; //鍏充簬鎴戜滑 @@ -412,9 +425,10 @@ public override int FormActionAgainEvent() { //鐢ㄦ埛澶村儚 - if (btnUserIcon.UnSelectedImagePath != UserCenterResourse.UserInfo.UserIconFile) + if (UserCenterResourse.UserInfo.UserIconFileChanged == true) { - btnUserIcon.UnSelectedImagePath = UserCenterResourse.UserInfo.UserIconFile; + UserCenterResourse.UserInfo.UserIconFileChanged = false; + btnUserIcon.ImageBytes = Shared.IO.FileUtils.ReadFile(UserCenterResourse.UserInfo.UserIconFile); } //鐢ㄦ埛鍚嶅瓧 btnUserName.Text = UserCenterResourse.UserInfo.UserName; @@ -436,6 +450,9 @@ } } + //鍒锋柊淇℃伅鎻愮ず鎺т欢 + this.msgControl?.RefreshStatu(); + //鍒濆鍖栦富鑿滃崟鐨勬帶浠� this.InitMainMenuInfoControl(frameWhiteBack); -- Gitblit v1.8.0