/// <summary>
        /// Create a new instance of the popup component.
        /// </summary>
        public AdvancedPopup()
        {
            // set default values
            HeaderColor       = SystemColors.ControlDark;
            BodyColor         = SystemColors.Control;
            TitleColor        = System.Drawing.Color.Gray;
            ContentColor      = SystemColors.ControlText;
            BorderColor       = SystemColors.WindowFrame;
            ButtonBorderColor = SystemColors.WindowFrame;
            ButtonHoverColor  = SystemColors.Highlight;
            ContentHoverColor = SystemColors.HotTrack;
            GradientPower     = 50;
            ContentFont       = SystemFonts.DialogFont;
            TitleFont         = SystemFonts.CaptionFont;
            ShowGrip          = true;
            Scroll            = true;
            TitlePadding      = new Padding(0);
            ContentPadding    = new Padding(0);
            ImagePadding      = new Padding(0);
            HeaderHeight      = 9;
            ShowCloseButton   = true;
            ShowOptionsButton = false;
            Delay             = 3000;
            AnimationInterval = 10;
            AnimationDuration = 1000;
            Size = new Size(400, 100);

            frmPopup                    = new PopupNotifierForm(this);
            frmPopup.TopMost            = true;
            frmPopup.FormBorderStyle    = System.Windows.Forms.FormBorderStyle.None;
            frmPopup.StartPosition      = System.Windows.Forms.FormStartPosition.Manual;
            frmPopup.FormBorderStyle    = System.Windows.Forms.FormBorderStyle.None;
            frmPopup.MouseEnter        += new EventHandler(frmPopup_MouseEnter);
            frmPopup.MouseLeave        += new EventHandler(frmPopup_MouseLeave);
            frmPopup.CloseClick        += new EventHandler(frmPopup_CloseClick);
            frmPopup.LinkClick         += new EventHandler(frmPopup_LinkClick);
            frmPopup.ContextMenuOpened += new EventHandler(frmPopup_ContextMenuOpened);
            frmPopup.ContextMenuClosed += new EventHandler(frmPopup_ContextMenuClosed);

            tmrAnimation       = new Timer();
            tmrAnimation.Tick += new EventHandler(tmAnimation_Tick);

            tmrWait       = new Timer();
            tmrWait.Tick += new EventHandler(tmWait_Tick);
        }
Пример #2
0
        /// <summary>
        /// Create a new instance of the popup component.
        /// </summary>
        public AdvancedPopup()
        {
            // set default values
            HeaderColor = SystemColors.ControlDark;
            BodyColor = SystemColors.Control;
            TitleColor = System.Drawing.Color.Gray;
            ContentColor = SystemColors.ControlText;
            BorderColor = SystemColors.WindowFrame;
            ButtonBorderColor = SystemColors.WindowFrame;
            ButtonHoverColor = SystemColors.Highlight;
            ContentHoverColor = SystemColors.HotTrack;
            GradientPower = 50;
            ContentFont = SystemFonts.DialogFont;
            TitleFont = SystemFonts.CaptionFont;
            ShowGrip = true;
            Scroll = true;
            TitlePadding = new Padding(0);
            ContentPadding = new Padding(0);
            ImagePadding = new Padding(0);
            HeaderHeight = 9;
            ShowCloseButton = true;
            ShowOptionsButton = false;
            Delay = 3000;
            AnimationInterval = 10;
            AnimationDuration = 1000;
            Size = new Size(400, 100);

            frmPopup = new PopupNotifierForm(this);
            frmPopup.TopMost = true;
            frmPopup.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
            frmPopup.StartPosition = System.Windows.Forms.FormStartPosition.Manual;
            frmPopup.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
            frmPopup.MouseEnter += new EventHandler(frmPopup_MouseEnter);
            frmPopup.MouseLeave += new EventHandler(frmPopup_MouseLeave);
            frmPopup.CloseClick += new EventHandler(frmPopup_CloseClick);
            frmPopup.LinkClick += new EventHandler(frmPopup_LinkClick);
            frmPopup.ContextMenuOpened += new EventHandler(frmPopup_ContextMenuOpened);
            frmPopup.ContextMenuClosed += new EventHandler(frmPopup_ContextMenuClosed);

            tmrAnimation = new Timer();
            tmrAnimation.Tick += new EventHandler(tmAnimation_Tick);

            tmrWait = new Timer();
            tmrWait.Tick += new EventHandler(tmWait_Tick);
        }