From 18a7f9f40e5fab3bee5d4ac3d8fd0273dea052d6 Mon Sep 17 00:00:00 2001 From: 黄学彪 <hxb@hdlchina.com.cn> Date: 星期日, 26 四月 2020 12:05:28 +0800 Subject: [PATCH] 先上传一个非最新的版本 --- ZigbeeApp/Shared/Phone/UserCenter/UserMain/UserMainForm.cs | 80 ++++++++++++++++++++++++++++------------ 1 files changed, 56 insertions(+), 24 deletions(-) diff --git a/ZigbeeApp/Shared/Phone/UserCenter/UserMain/UserMainForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/UserMain/UserMainForm.cs index 591c299..a19f778 100755 --- a/ZigbeeApp/Shared/Phone/UserCenter/UserMain/UserMainForm.cs +++ b/ZigbeeApp/Shared/Phone/UserCenter/UserMain/UserMainForm.cs @@ -75,12 +75,6 @@ //娓呯┖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; @@ -90,6 +84,21 @@ btnTitle.IsBold = true; btnTitle.TextID = R.MyInternationalizationString.UserCenter; bodyFrameLayout.AddChidren(btnTitle); + + var btnBack1 = new PicViewControl(1031, 942); + btnBack1.Y = btnTitle.Bottom - Application.GetRealHeight(10); + btnBack1.UnSelectedImagePath = "Center/MainBack1.png"; + bodyFrameLayout.AddChidren(btnBack1); + var btnBack2 = new PicViewControl(392, 172); + btnBack2.X = Application.GetRealWidth(688); + btnBack2.UnSelectedImagePath = "Center/MainBack2.png"; + bodyFrameLayout.AddChidren(btnBack2); + + //淇℃伅鎻愮ず鎺т欢 + this.msgControl = new MessageManagementControl(); + msgControl.Y = Application.GetRealHeight(127); + msgControl.X = Application.GetRealWidth(953); + bodyFrameLayout.AddChidren(this.msgControl); //鐧芥 var frameBack = new FrameLayout(); @@ -132,18 +141,24 @@ btnUserIcon.Y = frameWhite.Y - Application.GetRealHeight(109); btnUserIcon.MouseUpEventHandler += (sender, e) => { + if (Common.Config.Instance.Home.IsVirtually == true) + { + //濡傛灉鏀逛綇瀹呬负铏氭嫙浣忓畢,鍒欐鍔熻兘鏃犳晥 + return; + } var form = new UserInformationForm(); form.AddForm(); }; - if (UserCenterResourse.UserInfo.AuthorityNo == 1) + //鐨囧啝 + this.btnImperialCrown = new IconViewControl(60); + btnImperialCrown.X = Application.GetRealWidth(346); + btnImperialCrown.Y = Application.GetRealHeight(475); + btnImperialCrown.UnSelectedImagePath = "Center/ImperialCrown.png"; + bodyFrameLayout.AddChidren(btnImperialCrown); + if (UserCenterResourse.UserInfo.AuthorityNo != 1) { - //鐨囧啝 - this.btnImperialCrown = new IconViewControl(60); - btnImperialCrown.X = Application.GetRealWidth(346); - btnImperialCrown.Y = Application.GetRealHeight(475); - btnImperialCrown.UnSelectedImagePath = "Center/ImperialCrown.png"; - bodyFrameLayout.AddChidren(btnImperialCrown); + btnImperialCrown.Visible = false; } //鐢ㄦ埛鏄电О @@ -161,7 +176,7 @@ this.btnAuthority = new NormalViewControl(605, 60, true); btnAuthority.X = btnUserName.X; btnAuthority.Y = btnUserName.Bottom; - btnAuthority.TextColor = UserCenterColor.Current.Gray; + btnAuthority.TextColor = UserCenterColor.Current.TextGrayColor3; btnAuthority.TextSize = 12; if (UserCenterResourse.UserInfo != null) { @@ -237,6 +252,11 @@ var frame = this.CreatMainMenuControl(frameMenu, TextID, unSelectPic); frame.ButtonClickEvent += (sender, e) => { + if (Common.Config.Instance.Home.IsVirtually == true) + { + //濡傛灉鏀逛綇瀹呬负铏氭嫙浣忓畢,鍒欐鍔熻兘鏃犳晥 + return; + } var form = new Member.MemberListForm(); form.AddForm(); }; @@ -290,6 +310,11 @@ var frame = this.CreatMainMenuControl(frameMenu, TextID, unSelectPic); frame.ButtonClickEvent += (sender, e) => { + if (Common.Config.Instance.Home.IsVirtually == true) + { + //濡傛灉鏀逛綇瀹呬负铏氭嫙浣忓畢,鍒欐鍔熻兘鏃犳晥 + return; + } var form = new Safety.SafetyManagementMainForm(); form.AddForm(); }; @@ -378,6 +403,11 @@ btnBackView.X -= ControlCommonResourse.XXLeft / 2; rowback.ButtonClickEvent += (sender, e) => { + if (Common.Config.Instance.Home.IsVirtually == true) + { + //濡傛灉鏀逛綇瀹呬负铏氭嫙浣忓畢,鍒欐鍔熻兘鏃犳晥 + return; + } var form = new HdlBackup.HdlBackupListForm(); form.AddForm(); }; @@ -423,6 +453,11 @@ btnAbountView.X -= ControlCommonResourse.XXLeft / 2; rowAbount.ButtonClickEvent += (sender, e) => { + if (Common.Config.Instance.Home.IsVirtually == true) + { + //濡傛灉鏀逛綇瀹呬负铏氭嫙浣忓畢,鍒欐鍔熻兘鏃犳晥 + return; + } var form = new Abount.AbountForm(); form.AddForm(); }; @@ -475,17 +510,14 @@ //鐢ㄦ埛韬唤 btnAuthority.Text = UserCenterResourse.UserInfo.AuthorityText; } - if (this.btnImperialCrown != null) + //鐨囧啝 + if (UserCenterResourse.UserInfo.AuthorityNo != 1) { - //鐨囧啝 - if (UserCenterResourse.UserInfo.AuthorityNo != 1) - { - this.btnImperialCrown.Visible = false; - } - else - { - this.btnImperialCrown.Visible = true; - } + this.btnImperialCrown.Visible = false; + } + else + { + this.btnImperialCrown.Visible = true; } //鍒锋柊淇℃伅鎻愮ず鎺т欢 -- Gitblit v1.8.0