📄 applyforjoinform.cs
字号:
this.xlblMemberCountTag.Name = "xlblMemberCountTag";
this.xlblMemberCountTag.Size = new Size(0x37, 13);
this.xlblMemberCountTag.TabIndex = 5;
this.xlblMemberCountTag.Text = "成员数:";
this.xlblCatagoryTag.set_AutoSize(true);
this.xlblCatagoryTag.BorderColor = Color.Empty;
this.xlblCatagoryTag.ButtonBorderStyle = ButtonBorderStyle.None;
this.xlblCatagoryTag.Location = new System.Drawing.Point(0x55, 0x38);
this.xlblCatagoryTag.Name = "xlblCatagoryTag";
this.xlblCatagoryTag.Size = new Size(0x37, 13);
this.xlblCatagoryTag.TabIndex = 9;
this.xlblCatagoryTag.Text = "群分类:";
this.xlblGroupIntroduce.set_AutoSize(true);
this.xlblGroupIntroduce.BorderColor = Color.Empty;
this.xlblGroupIntroduce.ButtonBorderStyle = ButtonBorderStyle.None;
this.xlblGroupIntroduce.Location = new System.Drawing.Point(0x55, 0x66);
this.xlblGroupIntroduce.Name = "xlblGroupIntroduce";
this.xlblGroupIntroduce.Size = new Size(0x37, 13);
this.xlblGroupIntroduce.TabIndex = 3;
this.xlblGroupIntroduce.Text = "群简介:";
this.xlblGroupName.set_AutoSize(true);
this.xlblGroupName.BorderColor = Color.Empty;
this.xlblGroupName.ButtonBorderStyle = ButtonBorderStyle.None;
this.xlblGroupName.Location = new System.Drawing.Point(0x55, 10);
this.xlblGroupName.Name = "xlblGroupName";
this.xlblGroupName.Size = new Size(0x37, 13);
this.xlblGroupName.TabIndex = 1;
this.xlblGroupName.Text = "群名称:";
this.lblGroupName.set_AutoEllipsis(true);
this.lblGroupName.Location = new System.Drawing.Point(0x8a, 10);
this.lblGroupName.Name = "lblGroupName";
this.lblGroupName.Size = new Size(0xc7, 0x10);
this.lblGroupName.TabIndex = 7;
this.lblGroupName.Text = "groupName";
this.lblGroupName.UseMnemonic = false;
this.xtbIntroduce.BackColor = Color.FromArgb(240, 240, 240);
this.xtbIntroduce.BorderStyle = BorderStyle.FixedSingle;
this.xtbIntroduce.EmptyTextTip = "";
this.xtbIntroduce.EmptyTextTipColor = Color.DarkGray;
this.xtbIntroduce.Location = new System.Drawing.Point(140, 0x66);
this.xtbIntroduce.MaxLength = 0x100;
this.xtbIntroduce.Multiline = true;
this.xtbIntroduce.Name = "xtbIntroduce";
this.xtbIntroduce.ReadOnly = true;
this.xtbIntroduce.ScrollBars = ScrollBars.Vertical;
this.xtbIntroduce.Size = new Size(0xc5, 0x43);
this.xtbIntroduce.TabIndex = 4;
this.lblGroupId.set_AutoEllipsis(true);
this.lblGroupId.Location = new System.Drawing.Point(0x8a, 0x21);
this.lblGroupId.Name = "lblGroupId";
this.lblGroupId.Size = new Size(0xc7, 0x10);
this.lblGroupId.TabIndex = 6;
this.lblGroupId.Text = "groupid";
this.lblGroupId.UseMnemonic = false;
this.pnlPortrait.BackColor = Color.Silver;
this.pnlPortrait.Controls.Add(this.xpbPortrait);
this.pnlPortrait.Location = new System.Drawing.Point(10, 10);
this.pnlPortrait.Name = "pnlPortrait";
this.pnlPortrait.set_Padding(new Padding(1));
this.pnlPortrait.Size = new Size(0x41, 0x41);
this.pnlPortrait.TabIndex = 5;
this.xpbPortrait.BackColor = Color.White;
this.xpbPortrait.BorderColor = Color.Black;
this.xpbPortrait.BorderStyle = BorderStyle.None;
this.xpbPortrait.ButtonBorderStyle = ButtonBorderStyle.Solid;
this.xpbPortrait.Dock = DockStyle.Fill;
this.xpbPortrait.Image = null;
this.xpbPortrait.Location = new System.Drawing.Point(1, 1);
this.xpbPortrait.Name = "xpbPortrait";
this.xpbPortrait.Size = new Size(0x3f, 0x3f);
this.xpbPortrait.SizeMode = PictureBoxSizeMode.StretchImage;
this.xpbPortrait.TabIndex = 0;
this.xpbPortrait.Text = "xPictureBox1";
this.xlblGroupID.set_AutoSize(true);
this.xlblGroupID.BorderColor = Color.Empty;
this.xlblGroupID.ButtonBorderStyle = ButtonBorderStyle.None;
this.xlblGroupID.Location = new System.Drawing.Point(0x55, 0x21);
this.xlblGroupID.Name = "xlblGroupID";
this.xlblGroupID.Size = new Size(0x36, 13);
this.xlblGroupID.TabIndex = 2;
this.xlblGroupID.Text = "群 ID:";
this.xbtnOK.AutoArrangementX = true;
this.xbtnOK.AutoSizeToImage = false;
this.xbtnOK.BackColor = Color.Transparent;
this.xbtnOK.BackgroundImageDisable = null;
this.xbtnOK.BackgroundImageDown = null;
this.xbtnOK.BackgroundImageHover = null;
this.xbtnOK.ChangeSkin = true;
this.xbtnOK.DialogResult = DialogResult.OK;
this.xbtnOK.Location = new System.Drawing.Point(0xdd, 0x156);
this.xbtnOK.Name = "xbtnOK";
this.xbtnOK.Size = new Size(0x4b, 0x19);
this.xbtnOK.TabIndex = 0;
this.xbtnOK.Text = "确定";
this.xbtnOK.set_UseVisualStyleBackColor(false);
this.xbtnOK.Click += new EventHandler(this.xbtnOK_Click);
this.xbtnCancel.AutoArrangementX = true;
this.xbtnCancel.AutoSizeToImage = false;
this.xbtnCancel.BackColor = Color.Transparent;
this.xbtnCancel.BackgroundImageDisable = null;
this.xbtnCancel.BackgroundImageDown = null;
this.xbtnCancel.BackgroundImageHover = null;
this.xbtnCancel.ChangeSkin = true;
this.xbtnCancel.DialogResult = DialogResult.Cancel;
this.xbtnCancel.Location = new System.Drawing.Point(0x12e, 0x156);
this.xbtnCancel.Name = "xbtnCancel";
this.xbtnCancel.Size = new Size(0x4b, 0x19);
this.xbtnCancel.TabIndex = 1;
this.xbtnCancel.Text = "取消";
this.xbtnCancel.set_UseVisualStyleBackColor(false);
this.xbtnCancel.Click += new EventHandler(this.xbtnCancel_Click);
base.set_AutoScaleDimensions(new SizeF(6f, 13f));
base.set_AutoScaleMode(1);
base.BaseHeight = 0x191;
base.BaseWidth = 0x192;
base.CancelButton = this.xbtnCancel;
base.ClientSize = new Size(0x18c, 0x177);
base.Controls.Add(this.xbtnOK);
base.Controls.Add(this.xbtnCancel);
base.Controls.Add(this.pnlContent);
base.DisplayLocation = new System.Drawing.Point(0x12, 0x16);
base.Icon = (Icon) manager.GetObject("$this.Icon");
base.Name = "ApplyForJoinForm";
base.set_Padding(new Padding(6, 0x22, 0x13, 9));
base.Text = "申请加入";
base.Activated += new EventHandler(this.ApplyForJoinForm_Activated);
base.add_FormClosing(new FormClosingEventHandler(this, (IntPtr) this.ApplyForJoinForm_FormClosing));
this.pnlContent.ResumeLayout(false);
this.pnlContent.PerformLayout();
this.pnlApplyNote.ResumeLayout(false);
this.pnlApplyNote.PerformLayout();
this.pnlGroupInfo.ResumeLayout(false);
this.pnlGroupInfo.PerformLayout();
this.pnlPortrait.ResumeLayout(false);
base.ResumeLayout(false);
}
protected override void OnClosed(EventArgs e)
{
try
{
this.CurrentUser.StatusChanged -= new EventHandler<UserSatusChangedEventArgs>(this, (IntPtr) this.CurrentUser_StatusChanged);
}
catch (Exception exception)
{
ClientLogger.WriteException(exception);
}
base.OnClosed(e);
}
private void UpdateGroupInfo(bool seeDetail)
{
this.xlblGroupName.Text = StringTable.CreatePersonalGroup.GroupNamePrompt;
this.lblGroupId.Text = this._personalgroup.GroupInfo.Id;
string text = this._personalgroup.GroupInfo.Name.Value;
this.lblGroupName.Text = text;
this.xlblCatagory.Text = this.getCategoryString(this._personalgroup.GroupInfo.Category.Value);
this.xlblMembersCount.Text = string.Format("{0}/{1}", this._personalgroup.GroupInfo.MembersCount.ToString(), this._personalgroup.GroupInfo.LimitMemberCount.ToString());
this.xtbIntroduce.Text = this._personalgroup.GroupInfo.Introduce.Value;
switch (this._personalgroup.GroupInfo.ValidateType.Value)
{
case PersonalGroupValidateType.AllAgree:
this.xlblAttention.Text = StringTable.SearchPersonalGroup.Attention_AllAgree;
break;
case PersonalGroupValidateType.AllRejct:
this.xlblAttention.Text = StringTable.SearchPersonalGroup.Attention_AllReject;
break;
case PersonalGroupValidateType.NeedValidate:
this.xlblAttention.Text = StringTable.SearchPersonalGroup.Attention_NeedApprove;
break;
default:
this.xlblAttention.Text = "";
break;
}
if (this.CurrentUser.PersonalGroups[this._personalgroup.Uri] != null)
{
this.xpbPortrait.Image = (Image) this.CurrentUser.PersonalGroups[this._personalgroup.Uri].GroupInfo.Portrait;
}
else
{
try
{
this.CurrentUser.PersonalGroupManager.AsyncDownLoadGroupPortrait(this._personalgroup);
}
catch (Exception exception)
{
ClientLogger.WriteException(exception);
}
}
if (seeDetail)
{
this.pnlApplyNote.Visible = false;
this.pnlContent.Height = 220;
this.xbtnOK.Visible = false;
this.xbtnCancel.Text = "关闭";
base.Text = string.Format("{0}", this._personalgroup.GroupInfo.Name.Value);
}
else
{
if ((((PersonalGroupValidateType) this._personalgroup.GroupInfo.ValidateType.Value) == PersonalGroupValidateType.AllAgree) || (((PersonalGroupValidateType) this._personalgroup.GroupInfo.ValidateType.Value) == PersonalGroupValidateType.AllRejct))
{
this.pnlApplyNote.Visible = false;
this.pnlContent.Height = 220;
}
base.Text = string.Format("申请加入群 - {0}", this._personalgroup.GroupInfo.Name.Value);
}
}
private void xbtnCancel_Click(object sender, EventArgs e)
{
base.Close();
}
private void xbtnOK_Click(object sender, EventArgs e)
{
try
{
if (!this._seeDetail && (((PersonalGroupValidateType) this._personalgroup.GroupInfo.ValidateType.Value) != PersonalGroupValidateType.AllRejct))
{
if (this.CurrentUser.PersonalGroups[this._personalgroup.Uri] != null)
{
return;
}
this.ApplyNote = this.xtbApplyNote.Text;
}
}
catch (Exception exception)
{
ClientLogger.WriteException(exception);
}
base.Close();
}
public string ApplyNote
{
get
{
return this._applyNote;
}
internal set
{
this._applyNote = value;
}
}
private Imps.Client.Core.User CurrentUser
{
get
{
return this._framework.AccountManager.CurrentUser;
}
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -