public ContextPanel()
        {
            PopUpContextMenu = new ContextMenuStrip
            {
                BackColor = LayoutColors.ColorControlBack,
                ForeColor = LayoutColors.ColorControlText
            };
            PopUpContextMenu.MouseEnter += ContextMenuMouseEnter;
            PopUpContextMenu.MouseLeave += ContextMenuMouseLeave;

            _contextMenuTimer       = new Timer();
            _contextMenuTimer.Tick += ContextMenuTimerTick;

            _contextButton = new ContextButton {
                Parent = this, Visible = false
            };
            _contextButton.MouseClick       += ContextButtonOnMouseClick;
            _contextButton.MouseDoubleClick += ContextButtonOnMouseClick;
            _contextButton.MouseEnter       += ContextButtonMouseEnter;
            _contextButton.MouseLeave       += ContextButtonMouseLeave;

            _closeButton = new CloseButton {
                Parent = this, Visible = false
            };
        }
Exemplo n.º 2
0
        public ContextPanel()
        {
            PopUpContextMenu = new ContextMenuStrip
                {
                    BackColor = LayoutColors.ColorControlBack,
                    ForeColor = LayoutColors.ColorControlText
                };
            PopUpContextMenu.MouseEnter += ContextMenuMouseEnter;
            PopUpContextMenu.MouseLeave += ContextMenuMouseLeave;

            contextMenuTimer = new Timer();
            contextMenuTimer.Tick += ContextMenuTimerTick;

            contextButton = new ContextButton {Parent = this, Visible = false};
            contextButton.MouseClick += ContextButtonOnMouseClick;
            contextButton.MouseDoubleClick += ContextButtonOnMouseClick;
            contextButton.MouseEnter += ContextButtonMouseEnter;
            contextButton.MouseLeave += ContextButtonMouseLeave;

            closeButton = new CloseButton {Parent = this, Visible = false};
        }