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

📄 systeminfonotify.cs

📁 破解的飞信源代码
💻 CS
字号:
namespace Imps.Client.Pc
{
    using Imps.Client.Core;
    using Imps.Client.Pc.BizControls.NotifyWindows;
    using Imps.Client.Pc.BizControls.NotifyWindows.Templates;
    using Imps.Client.Utils;
    using System;
    using System.Drawing;

    public class SystemInfoNotify : NotifyWindowTemplateBase
    {
        private Imps.Client.Core.SystemMessage _msg;
        protected NotifyWindowLabel contentLabel;
        protected NotifyWindowLabel linkLabel;
        protected NotifyWindowLabel titleLabel;

        public SystemInfoNotify(string title, Imps.Client.Core.SystemMessage msg)
        {
            base.title = title;
            this._msg = msg;
            base.InitContent();
        }

        public SystemInfoNotify(string title, string content) : this(string.Empty, new Imps.Client.Core.SystemMessage(string.Empty, content, string.Empty, string.Empty))
        {
        }

        private void contentLabel_Click(object sender, NotifyWindowEventArgs e)
        {
            if (!string.IsNullOrEmpty(this._msg.Link))
            {
                ShellHelper.StartUrl(this._msg.Link);
                base.Close();
            }
        }

        protected override void CreateContent(NotifyWindowContent content)
        {
            if (!string.IsNullOrEmpty(this._msg.Link))
            {
                Rectangle textRectangle = new Rectangle(content.Rectangle.X + 10, content.Rectangle.Y, 180, 50);
                this.contentLabel = new NotifyWindowLabel(this._msg.Content, textRectangle);
                content.Elements.Add(this.contentLabel);
                Rectangle rectangle2 = new Rectangle(content.Rectangle.X + 110, content.Rectangle.Y + 0x37, 180, 0x19);
                this.linkLabel = new NotifyWindowLabel("更多详细信息", rectangle2);
                this.linkLabel.TextFont = new Font("宋体", 12f, FontStyle.Underline, GraphicsUnit.Pixel);
                this.linkLabel.TextColor = Color.Blue;
                this.linkLabel.Clickable = true;
                this.linkLabel.Click += new NotifyWindowEventHandler(this.contentLabel_Click);
                content.Elements.Add(this.linkLabel);
            }
            else
            {
                Rectangle rectangle3 = new Rectangle(12, content.Rectangle.Y + 3, 180, 80);
                this.contentLabel = new NotifyWindowLabel(this._msg.Content, rectangle3);
                content.Elements.Add(this.contentLabel);
            }
            Rectangle rectangle4 = new Rectangle((NotifyWindowTemplateBase.Style.CaptionX + base.captionImage.Width) + 3, NotifyWindowTemplateBase.Style.CaptionY - 2, 100, 15);
            this.titleLabel = new NotifyWindowLabel(base.title, rectangle4);
            this.titleLabel.TextFont = new Font("宋体", 12f, FontStyle.Bold, GraphicsUnit.Pixel);
            this.titleLabel.TextColor = Color.White;
            this.titleLabel.HoverTextFont = new Font("宋体", 12f, FontStyle.Bold, GraphicsUnit.Pixel);
            this.titleLabel.HoverTextColor = Color.White;
            content.Elements.Add(this.titleLabel);
        }

        public Imps.Client.Core.SystemMessage SystemMessage
        {
            get
            {
                return this._msg;
            }
        }
    }
}

⌨️ 快捷键说明

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