⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 permissioncontrol.cs

📁 破解的飞信源代码
💻 CS
📖 第 1 页 / 共 2 页
字号:
namespace Imps.Client.Pc.UIContactList
{
    using Imps.Client.Core;
    using Imps.Client.Pc;
    using Imps.Client.Pc.Controls;
    using Imps.Client.Utils;
    using Imps.Common;
    using Imps.Common.Permission;
    using System;
    using System.ComponentModel;
    using System.Drawing;
    using System.Windows.Forms;

    public class PermissionControl : ProfileControlBase
    {
        private Contact _contact;
        private IFrameworkWindow _iFrameworkWindow;
        private User _user;
        private CheckBox cbBirthday;
        private CheckBox cbBiz;
        private CheckBox cbEmail;
        private CheckBox cbPhone;
        private CheckBox cbShareInfo;
        private CheckBox checkBoxBlock;
        private CheckBox chkPresence;
        private IContainer components;
        private GroupBox groupBox1;
        private GroupBox groupBox2;
        private GroupBox groupBox3;
        private XLabel label5;
        private XLabel lbIvr;
        private RadioButton rbIvr_Agree;
        private RadioButton rbIvr_Aprove;
        private RadioButton rbIvr_Deny;

        public PermissionControl(IFrameworkWindow iFrameworkWnd, Contact contact)
        {
            this.InitializeComponent();
            this._iFrameworkWindow = iFrameworkWnd;
            this._user = iFrameworkWnd.AccountManager.CurrentUser;
            this._contact = contact;
            this.HandleUiChanged();
        }

        private void _contact_IsBlockChanged(object sender, BlockEventArgs e)
        {
            this.checkBoxBlock.Checked = this._contact.IsBlocked;
        }

        private void checkBoxBlock_CheckedChanged(object sender, EventArgs e)
        {
            this.groupBox1.Enabled = !this.checkBoxBlock.Checked;
            this.groupBox2.Enabled = !this.checkBoxBlock.Checked;
        }

        public override bool ControlLoad()
        {
            this._contact.IsBlockChanged += new EventHandler<BlockEventArgs>(this, (IntPtr) this._contact_IsBlockChanged);
            return base.ControlLoad();
        }

        public override bool ControlUnload()
        {
            this._contact.IsBlockChanged -= new EventHandler<BlockEventArgs>(this, (IntPtr) this._contact_IsBlockChanged);
            return base.ControlUnload();
        }

        protected override void Dispose(bool disposing)
        {
            if (disposing && (this.components != null))
            {
                this.components.Dispose();
            }
            base.Dispose(disposing);
        }

        protected override void HandleUiChanged()
        {
            this.cbShareInfo.CheckedChanged += new EventHandler(this.UIData_Changed);
            this.cbBirthday.CheckedChanged += new EventHandler(this.UIData_Changed);
            this.cbBiz.CheckedChanged += new EventHandler(this.UIData_Changed);
            this.cbEmail.CheckedChanged += new EventHandler(this.UIData_Changed);
            this.cbPhone.CheckedChanged += new EventHandler(this.UIData_Changed);
            this.chkPresence.Click += new EventHandler(this.UIData_Changed);
            this.rbIvr_Agree.CheckedChanged += new EventHandler(this.UIData_Changed);
            this.rbIvr_Aprove.CheckedChanged += new EventHandler(this.UIData_Changed);
            this.rbIvr_Deny.CheckedChanged += new EventHandler(this.UIData_Changed);
            this.checkBoxBlock.CheckedChanged += new EventHandler(this.UIData_Changed);
        }

        private void InitializeComponent()
        {
            this.cbShareInfo = new CheckBox();
            this.checkBoxBlock = new CheckBox();
            this.label5 = new XLabel();
            this.chkPresence = new CheckBox();
            this.groupBox1 = new GroupBox();
            this.cbPhone = new CheckBox();
            this.cbBiz = new CheckBox();
            this.cbEmail = new CheckBox();
            this.cbBirthday = new CheckBox();
            this.groupBox2 = new GroupBox();
            this.rbIvr_Deny = new RadioButton();
            this.rbIvr_Aprove = new RadioButton();
            this.rbIvr_Agree = new RadioButton();
            this.lbIvr = new XLabel();
            this.groupBox3 = new GroupBox();
            this.groupBox1.SuspendLayout();
            this.groupBox2.SuspendLayout();
            this.groupBox3.SuspendLayout();
            base.SuspendLayout();
            this.cbShareInfo.set_AutoSize(true);
            this.cbShareInfo.Location = new System.Drawing.Point(0x25, 30);
            this.cbShareInfo.Name = "cbShareInfo";
            this.cbShareInfo.Size = new Size(0xc2, 0x11);
            this.cbShareInfo.TabIndex = 2;
            this.cbShareInfo.Text = "向对方公开我的手机号码和姓名";
            this.cbShareInfo.set_UseVisualStyleBackColor(true);
            this.checkBoxBlock.set_AutoSize(true);
            this.checkBoxBlock.Location = new System.Drawing.Point(0x25, 0x19);
            this.checkBoxBlock.Name = "checkBoxBlock";
            this.checkBoxBlock.Size = new Size(0x92, 0x11);
            this.checkBoxBlock.TabIndex = 8;
            this.checkBoxBlock.Text = "我要将对方加入黑名单";
            this.checkBoxBlock.set_UseVisualStyleBackColor(true);
            this.checkBoxBlock.CheckedChanged += new EventHandler(this.checkBoxBlock_CheckedChanged);
            this.label5.BorderColor = Color.Empty;
            this.label5.ButtonBorderStyle = ButtonBorderStyle.None;
            this.label5.ForeColor = Color.Red;
            this.label5.Location = new System.Drawing.Point(0x22, 0x31);
            this.label5.Name = "label5";
            this.label5.Size = new Size(0x12d, 40);
            this.label5.TabIndex = 10;
            this.label5.Text = "将对方加入黑名单后,对方将不能看到您的在线状态,也不能通过飞信直接和您联系。";
            this.chkPresence.CheckAlign = ContentAlignment.TopLeft;
            this.chkPresence.Location = new System.Drawing.Point(0x25, 0x9b);
            this.chkPresence.Name = "chkPresence";
            this.chkPresence.Size = new Size(0x113, 30);
            this.chkPresence.TabIndex = 14;
            this.chkPresence.Text = "允许对方看到我的在线状态以及其它状态信息(例如:我的彩铃)";
            this.chkPresence.set_UseVisualStyleBackColor(true);
            this.groupBox1.Controls.Add(this.cbPhone);
            this.groupBox1.Controls.Add(this.cbBiz);
            this.groupBox1.Controls.Add(this.cbEmail);
            this.groupBox1.Controls.Add(this.cbBirthday);
            this.groupBox1.Controls.Add(this.cbShareInfo);
            this.groupBox1.Controls.Add(this.chkPresence);
            this.groupBox1.Location = new System.Drawing.Point(3, 3);
            this.groupBox1.Name = "groupBox1";
            this.groupBox1.Size = new Size(0x16c, 0xc5);
            this.groupBox1.TabIndex = 0x10;
            this.groupBox1.TabStop = false;
            this.groupBox1.Text = "个人信息";
            this.cbPhone.set_AutoSize(true);
            this.cbPhone.BackColor = Color.Transparent;
            this.cbPhone.Location = new System.Drawing.Point(0x25, 80);
            this.cbPhone.Name = "cbPhone";
            this.cbPhone.Size = new Size(0x9e, 0x11);
            this.cbPhone.TabIndex = 0x10;
            this.cbPhone.Text = "向对方公开我的电话号码";
            this.cbPhone.set_UseVisualStyleBackColor(false);
            this.cbBiz.set_AutoSize(true);
            this.cbBiz.BackColor = Color.Transparent;
            this.cbBiz.Location = new System.Drawing.Point(0x25, 130);
            this.cbBiz.Name = "cbBiz";
            this.cbBiz.Size = new Size(0x7a, 0x11);
            this.cbBiz.TabIndex = 0x12;
            this.cbBiz.Text = "公开我的商务信息";
            this.cbBiz.set_UseVisualStyleBackColor(false);
            this.cbEmail.set_AutoSize(true);
            this.cbEmail.BackColor = Color.Transparent;
            this.cbEmail.Location = new System.Drawing.Point(0x25, 0x69);
            this.cbEmail.Name = "cbEmail";

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -