📄 pgagreementcontrol.cs
字号:
namespace Imps.Client.Pc
{
using Imps.Client.Core;
using Imps.Client.Pc.Controls;
using Imps.Client.Utils;
using System;
using System.ComponentModel;
using System.Drawing;
using System.Windows.Forms;
public class PGAgreementControl : UserControl
{
private IFrameworkWindow _framework;
private IContainer components;
private GroupBox gbDutyFreeDeclare;
private Panel panel1;
private Panel pnlBase;
private XLabel1 xlblPromption;
private XTextBox xtxtDutyFreeContent;
public PGAgreementControl(IFrameworkWindow wnd)
{
this._framework = wnd;
this.InitializeComponent();
AsyncBizOperation op = new AsyncBizOperation();
op.Successed += new EventHandler(this.op_Successed);
this._framework.AccountManager.CurrentUser.PersonalGroupManager.AsyncGetGroupResponsibility(op);
}
protected override void Dispose(bool disposing)
{
if (disposing && (this.components != null))
{
this.components.Dispose();
}
base.Dispose(disposing);
}
private void InitializeComponent()
{
this.pnlBase = new Panel();
this.panel1 = new Panel();
this.xlblPromption = new XLabel1();
this.gbDutyFreeDeclare = new GroupBox();
this.xtxtDutyFreeContent = new XTextBox();
this.pnlBase.SuspendLayout();
this.panel1.SuspendLayout();
this.gbDutyFreeDeclare.SuspendLayout();
base.SuspendLayout();
this.pnlBase.Controls.Add(this.panel1);
this.pnlBase.Controls.Add(this.gbDutyFreeDeclare);
this.pnlBase.Dock = DockStyle.Fill;
this.pnlBase.Location = new System.Drawing.Point(6, 3);
this.pnlBase.Name = "pnlBase";
this.pnlBase.Size = new Size(380, 0x16c);
this.pnlBase.TabIndex = 0;
this.panel1.Controls.Add(this.xlblPromption);
this.panel1.Dock = DockStyle.Top;
this.panel1.Location = new System.Drawing.Point(0, 0);
this.panel1.Name = "panel1";
this.panel1.Size = new Size(380, 0x1f);
this.panel1.TabIndex = 6;
this.xlblPromption.AutoEllipsis = false;
this.xlblPromption.BorderColor = Color.Black;
this.xlblPromption.BorderStyle = BorderStyle.None;
this.xlblPromption.ButtonBorderStyle = ButtonBorderStyle.Solid;
this.xlblPromption.ForeColor = Color.Green;
this.xlblPromption.Location = new System.Drawing.Point(0, 11);
this.xlblPromption.Name = "xlblPromption";
this.xlblPromption.Size = new Size(0x108, 0x17);
this.xlblPromption.TabIndex = 5;
this.xlblPromption.Text = "创建群前请仔细阅读声明条款";
this.xlblPromption.TextAlign = ContentAlignment.TopLeft;
this.xlblPromption.UseMnemonic = false;
this.gbDutyFreeDeclare.Controls.Add(this.xtxtDutyFreeContent);
this.gbDutyFreeDeclare.Dock = DockStyle.Bottom;
this.gbDutyFreeDeclare.Location = new System.Drawing.Point(0, 0x24);
this.gbDutyFreeDeclare.Name = "gbDutyFreeDeclare";
this.gbDutyFreeDeclare.Size = new Size(380, 0x148);
this.gbDutyFreeDeclare.TabIndex = 5;
this.gbDutyFreeDeclare.TabStop = false;
this.gbDutyFreeDeclare.Text = "免责声明";
this.xtxtDutyFreeContent.BackColor = Color.FromArgb(240, 240, 240);
this.xtxtDutyFreeContent.BorderStyle = BorderStyle.FixedSingle;
this.xtxtDutyFreeContent.Dock = DockStyle.Fill;
this.xtxtDutyFreeContent.EmptyTextTip = "";
this.xtxtDutyFreeContent.EmptyTextTipColor = Color.DarkGray;
this.xtxtDutyFreeContent.Location = new System.Drawing.Point(3, 0x10);
this.xtxtDutyFreeContent.Multiline = true;
this.xtxtDutyFreeContent.Name = "xtxtDutyFreeContent";
this.xtxtDutyFreeContent.ReadOnly = true;
this.xtxtDutyFreeContent.ScrollBars = ScrollBars.Vertical;
this.xtxtDutyFreeContent.Size = new Size(0x176, 0x135);
this.xtxtDutyFreeContent.TabIndex = 0;
this.xtxtDutyFreeContent.TabStop = false;
base.set_AutoScaleDimensions(new SizeF(6f, 13f));
base.set_AutoScaleMode(1);
this.BackColor = Color.Transparent;
base.Controls.Add(this.pnlBase);
base.Name = "PGAgreementControl";
base.set_Padding(new Padding(6, 3, 6, 3));
base.Size = new Size(0x188, 370);
this.pnlBase.ResumeLayout(false);
this.panel1.ResumeLayout(false);
this.gbDutyFreeDeclare.ResumeLayout(false);
this.gbDutyFreeDeclare.PerformLayout();
base.ResumeLayout(false);
}
private void op_Successed(object sender, EventArgs e)
{
try
{
this.xtxtDutyFreeContent.Text = (sender as AsyncBizOperation).ContextForBiz.ToString();
}
catch (Exception exception)
{
ClientLogger.WriteException(exception);
}
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -