黄学彪
2019-10-18 97e259d966cb5cb5d73c105d5dbaadcc1f920614
ZigbeeApp/Shared/Phone/UserCenter/UserMain/UserMainForm.cs
@@ -22,6 +22,14 @@
        /// 用户身份
        /// </summary>
        private NormalViewControl btnAuthority = null;
        /// <summary>
        /// 用户头像
        /// </summary>
        private IconViewControl btnUserIcon = null;
        /// <summary>
        /// 皇冠
        /// </summary>
        private IconViewControl btnImperialCrown = null;
        #endregion
@@ -99,7 +107,7 @@
        private void InitUserInfoControl(FrameLayout frameWhite)
        {
            //用户头像
            var btnUserIcon = new IconViewControl(280);
            this.btnUserIcon = new IconViewControl(280);
            btnUserIcon.X = Application.GetRealWidth(121);
            btnUserIcon.UnSelectedImagePath = UserCenterResourse.UserInfo.UserIconFile;
            bodyFrameLayout.AddChidren(btnUserIcon);
@@ -113,7 +121,7 @@
            if (UserCenterResourse.UserInfo.AuthorityNo == 1)
            {
                //皇冠
                var btnImperialCrown = new IconViewControl(60);
                this.btnImperialCrown = new IconViewControl(60);
                btnImperialCrown.X = Application.GetRealWidth(346);
                btnImperialCrown.Y = Application.GetRealHeight(475);
                btnImperialCrown.UnSelectedImagePath = "Center/ImperialCrown.png";
@@ -121,7 +129,7 @@
            }
            //用户昵称
            btnUserName = new NormalViewControl(605, 60, true);
            this.btnUserName = new NormalViewControl(605, 60, true);
            btnUserName.X = btnUserIcon.Right + Application.GetRealWidth(5);
            btnUserName.Y = Application.GetRealHeight(43);
            if (UserCenterResourse.UserInfo != null)
@@ -403,8 +411,8 @@
        /// </summary>
        public override int FormActionAgainEvent()
        {
            //不要删除这个函数
            base.FormActionAgainEvent();
            //用户头像
            btnUserIcon.UnSelectedImagePath = UserCenterResourse.UserInfo.UserIconFile;
            //用户名字
            btnUserName.Text = UserCenterResourse.UserInfo.UserName;
            if (UserCenterResourse.UserInfo != null)
@@ -412,6 +420,19 @@
                //用户身份
                btnAuthority.Text = UserCenterResourse.UserInfo.AuthorityText;
            }
            if (this.btnImperialCrown != null)
            {
                //皇冠
                if (UserCenterResourse.UserInfo.AuthorityNo != 1)
                {
                    this.btnImperialCrown.Visible = false;
                }
                else
                {
                    this.btnImperialCrown.Visible = true;
                }
            }
            //初始化主菜单的控件
            this.InitMainMenuInfoControl(frameWhiteBack);