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

📄 multiivrform.cs

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

    public class MultiIVRForm : IVRFormBase
    {
        private int _startTickets;
        private XButton btnCancel;
        private XButton btnClose;
        private XButton btnStart;
        private IContainer components;
        private XLabel label1;
        private XLabel label2;
        private XLabel lblBeInviteUsers;
        private XLabel lblChargeInfo;
        private XLabel lblCurrentUser;
        private XLabel lblInviteInfo;
        private IVRListBox lstContacts;
        private Panel panel1;
        private DisplayPortrait PicOwner;

        public MultiIVRForm(IFrameworkWindow frameworkWnd, Imps.Client.Pc.IVRManager manager, IVRDialog dialog) : base(frameworkWnd, manager, dialog)
        {
            this.InitializeComponent();
            scroll_widget _widget = scroll_maker.instance.vscroll();
            _widget.host = this.lstContacts;
            this.lstContacts.Parent.Controls.Add(_widget);
            this.initComponentRegion();
            this.lblInviteInfo.Text = "您正在发起手机语聊,请等待对方接受邀请。";
            this.lblChargeInfo.Text = base.ChargeInfo;
            this.lblBeInviteUsers.UseMnemonic = false;
            this.lblCurrentUser.UseMnemonic = false;
            this.lblInviteInfo.UseMnemonic = false;
            this.lblBeInviteUsers.UseMnemonic = false;
        }

        private void btnCancel_Click(object sender, EventArgs e)
        {
            base.Close();
        }

        private void btnClose_Click(object sender, EventArgs e)
        {
            base.Close();
        }

        private void btnStart_Click(object sender, EventArgs e)
        {
            UiErrorHelper.HandEventSafely(base.FrameworkWindow, delegate {
                if (!this.TryStartIVR())
                {
                    base.FrameworkWindow.UnifiedMessageBox.ShowInfo("必须有联系人接受才可以开始IVR会话!");
                }
            });
        }

        private void ContactList_ContactsChanged(object sender, ContactsChangedEventArgs e)
        {
            UiErrorHelper.HandEventSafely(base.FrameworkWindow, delegate {
                List<ContactChangedEventArgs>.Enumerator enumerator = e.ContactChangedEventArgsCollection.GetEnumerator();
                try
                {
                    while (enumerator.MoveNext())
                    {
                        Imps.Client.Core.Contact contact = enumerator.get_Current().Contact;
                        IVRListItem listItem = this.GetListItem(contact);
                        if (listItem != null)
                        {
                            Imps.Client.Core.IVR ivr = listItem.Context as Imps.Client.Core.IVR;
                            if ((ivr != null) && ((ivr.Status == IVRParticipantStatus.Accept) || (ivr.Status == IVRParticipantStatus.Inviting)))
                            {
                                listItem.Image = contact.PersonalInfo.Portrait;
                            }
                            listItem.Name = contact.DisplayName;
                            listItem.MoodePhrase = contact.Presence.MoodPhrase;
                        }
                    }
                }
                finally
                {
                    enumerator.Dispose();
                }
            });
        }

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

        private void FormatForm(string inviteInfo)
        {
            this.btnCancel.Visible = false;
            this.btnStart.Visible = false;
            this.btnClose.Visible = true;
            this.lblInviteInfo.ForeColor = Color.DarkOrchid;
            this.lblInviteInfo.Text = inviteInfo;
        }

        private IVRListItem GetListItem(Imps.Client.Core.Contact contact)
        {
            try
            {
                foreach (object obj2 in this.lstContacts.Items)
                {
                    if ((obj2 is IVRListItem) && (((obj2 as IVRListItem).Context as Imps.Client.Core.IVR).Contact == contact))
                    {
                        return (obj2 as IVRListItem);
                    }
                }
            }
            catch
            {
            }
            return null;
        }

        private void InitializeComponent()
        {
            ComponentResourceManager manager = new ComponentResourceManager(typeof(MultiIVRForm));
            this.panel1 = new Panel();
            this.lblCurrentUser = new XLabel();
            this.lblChargeInfo = new XLabel();
            this.lblInviteInfo = new XLabel();
            this.label2 = new XLabel();
            this.lblBeInviteUsers = new XLabel();
            this.label1 = new XLabel();
            this.lstContacts = new IVRListBox();
            this.PicOwner = new DisplayPortrait();
            this.btnClose = new XButton();
            this.btnCancel = new XButton();
            this.btnStart = new XButton();
            this.panel1.SuspendLayout();
            base.SuspendLayout();
            this.panel1.BackColor = Color.Transparent;
            this.panel1.Controls.Add(this.lblCurrentUser);
            this.panel1.Controls.Add(this.lblChargeInfo);
            this.panel1.Controls.Add(this.lblInviteInfo);
            this.panel1.Controls.Add(this.label2);
            this.panel1.Controls.Add(this.lblBeInviteUsers);
            this.panel1.Controls.Add(this.label1);
            this.panel1.Controls.Add(this.lstContacts);
            this.panel1.Controls.Add(this.PicOwner);
            this.panel1.Location = new System.Drawing.Point(4, 4);
            this.panel1.Name = "panel1";
            this.panel1.Size = new Size(0x1b2, 0x1a0);
            this.panel1.TabIndex = 0;
            this.lblCurrentUser.set_AutoEllipsis(true);
            this.lblCurrentUser.BorderColor = Color.Empty;
            this.lblCurrentUser.ButtonBorderStyle = ButtonBorderStyle.None;
            this.lblCurrentUser.ForeColor = SystemColors.Desktop;
            this.lblCurrentUser.Location = new System.Drawing.Point(0x89, 0x12);
            this.lblCurrentUser.Name = "lblCurrentUser";
            this.lblCurrentUser.set_Padding(new Padding(0, 1, 0, 1));
            this.lblCurrentUser.Size = new Size(280, 0x10);
            this.lblCurrentUser.TabIndex = 0x17;
            this.lblChargeInfo.BorderColor = Color.Empty;
            this.lblChargeInfo.ButtonBorderStyle = ButtonBorderStyle.None;
            this.lblChargeInfo.ForeColor = Color.DarkOrchid;
            this.lblChargeInfo.Location = new System.Drawing.Point(0x89, 0x5c);
            this.lblChargeInfo.Name = "lblChargeInfo";
            this.lblChargeInfo.Size = new Size(280, 40);
            this.lblChargeInfo.TabIndex = 0x16;
            this.lblChargeInfo.Text = "资费请咨询当地10086";
            this.lblInviteInfo.set_AutoEllipsis(true);
            this.lblInviteInfo.BorderColor = Color.Empty;
            this.lblInviteInfo.ButtonBorderStyle = ButtonBorderStyle.None;
            this.lblInviteInfo.Location = new System.Drawing.Point(0x89, 0x2e);
            this.lblInviteInfo.Name = "lblInviteInfo";
            this.lblInviteInfo.Size = new Size(280, 40);
            this.lblInviteInfo.TabIndex = 0x15;
            this.lblInviteInfo.Text = "您正在发起手机语聊,请等待对方接受邀请。";
            this.label2.BorderColor = Color.Empty;
            this.label2.BorderStyle = BorderStyle.Fixed3D;
            this.label2.ButtonBorderStyle = ButtonBorderStyle.None;
            this.label2.Location = new System.Drawing.Point(15, 400);
            this.label2.Name = "label2";
            this.label2.Size = new Size(0x17d, 2);
            this.label2.TabIndex = 6;
            this.lblBeInviteUsers.set_AutoSize(true);
            this.lblBeInviteUsers.BorderColor = Color.Empty;
            this.lblBeInviteUsers.ButtonBorderStyle = ButtonBorderStyle.None;
            this.lblBeInviteUsers.Font = new Font("Microsoft Sans Serif", 9f);
            this.lblBeInviteUsers.ForeColor = SystemColors.Desktop;
            this.lblBeInviteUsers.Location = new System.Drawing.Point(15, 0x9c);
            this.lblBeInviteUsers.Name = "lblBeInviteUsers";
            this.lblBeInviteUsers.Size = new Size(0x37, 15);
            this.lblBeInviteUsers.TabIndex = 3;
            this.lblBeInviteUsers.Text = "被邀请者";
            this.label1.BorderColor = Color.Empty;
            this.label1.BorderStyle = BorderStyle.Fixed3D;
            this.label1.ButtonBorderStyle = ButtonBorderStyle.None;
            this.label1.Location = new System.Drawing.Point(0x4c, 0xa3);
            this.label1.Name = "label1";
            this.label1.Size = new Size(320, 2);
            this.label1.TabIndex = 4;
            this.lstContacts.BackColor = Color.White;
            this.lstContacts.BorderStyle = BorderStyle.None;
            this.lstContacts.CancelDescription = "取消邀请";
            this.lstContacts.CancelImage = null;
            this.lstContacts.DisableColor = Color.FromArgb(0xa4, 170, 220);
            this.lstContacts.DrawMode = DrawMode.OwnerDrawVariable;
            this.lstContacts.set_FormattingEnabled(true);
            this.lstContacts.IVRItemHeight = 80;
            this.lstContacts.LnkFont = new Font("Microsoft Sans Serif", 9f, FontStyle.Underline, GraphicsUnit.Point, 0);
            this.lstContacts.Location = new System.Drawing.Point(30, 0xbc);
            this.lstContacts.MoodPhraseColor = Color.FromArgb(0xa4, 170, 220);
            this.lstContacts.MoodPhraseFont = new Font("Microsoft Sans Serif", 9f, FontStyle.Regular, GraphicsUnit.Point, 0);
            this.lstContacts.Name = "lstContacts";
            this.lstContacts.SeperatorHeight = 1;
            this.lstContacts.ShowOneLine = false;
            this.lstContacts.Size = new Size(0x17b, 0xc3);
            this.lstContacts.TabIndex = 5;
            this.PicOwner.BackColor = Color.White;
            this.PicOwner.BorderColor = Color.FromArgb(0xa4, 170, 220);
            this.PicOwner.Image = (Image) manager.GetObject("PicOwner.Image");
            this.PicOwner.Location = new System.Drawing.Point(14, 13);
            this.PicOwner.Name = "PicOwner";
            this.PicOwner.Size = new Size(0x76, 0x76);
            this.PicOwner.TabIndex = 0;
            this.PicOwner.ToolTipText = "";
            this.PicOwner.Click += new EventHandler(this.PicOwner_Click);
            this.btnClose.Anchor = AnchorStyles.Top;
            this.btnClose.AutoArrangementX = true;
            this.btnClose.AutoSizeToImage = false;
            this.btnClose.BackColor = Color.Transparent;
            this.btnClose.BackgroundImageDisable = null;
            this.btnClose.BackgroundImageDown = null;
            this.btnClose.BackgroundImageHover = null;
            this.btnClose.ChangeSkin = true;
            this.btnClose.Location = new System.Drawing.Point(350, 0x1aa);
            this.btnClose.Name = "btnClose";
            this.btnClose.Size = new Size(0x54, 0x17);
            this.btnClose.TabIndex = 8;
            this.btnClose.Text = "关闭";
            this.btnClose.set_UseVisualStyleBackColor(false);
            this.btnClose.Visible = false;
            this.btnClose.Click += new EventHandler(this.btnClose_Click);
            this.btnCancel.Anchor = AnchorStyles.Top;
            this.btnCancel.AutoArrangementX = true;
            this.btnCancel.AutoSizeToImage = false;
            this.btnCancel.BackColor = Color.Transparent;
            this.btnCancel.BackgroundImageDisable = null;
            this.btnCancel.BackgroundImageDown = null;
            this.btnCancel.BackgroundImageHover = null;
            this.btnCancel.ChangeSkin = true;
            this.btnCancel.Location = new System.Drawing.Point(0x10c, 0x1c7);
            this.btnCancel.Name = "btnCancel";
            this.btnCancel.Size = new Size(170, 0x17);
            this.btnCancel.TabIndex = 9;
            this.btnCancel.Text = "取消通话";
            this.btnCancel.set_UseVisualStyleBackColor(false);
            this.btnCancel.Click += new EventHandler(this.btnCancel_Click);
            this.btnStart.Anchor = AnchorStyles.Top;
            this.btnStart.AutoArrangementX = true;
            this.btnStart.AutoSizeToImage = false;

⌨️ 快捷键说明

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