System.Windows.Forms.Button.OnClick(System.EventArgs)

Here are the examples of the csharp api class System.Windows.Forms.Button.OnClick(System.EventArgs) taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.

21 Examples 7

1. Example

Project: RNGReporter
Source File: GlassButton.cs
protected override void OnClick(EventArgs e)
        {
            _isKeyDown = _isMouseDown = false;
            base.OnClick(e);
        }

2. Example

Project: dockpanelsuite
Source File: InertButton.cs
protected override void OnClick(EventArgs e)
        {
            if (RepeatClick && !(e is RepeatClickEventArgs))
                return;

            base.OnClick (e);
        }

3. Example

Project: DropboxBusinessAdminTool
Source File: ButtonEx.cs
protected override void OnClick(EventArgs e) {
            base.OnClick(e);
        }

4. Example

Project: sharpshell
Source File: SplitButton.cs
protected override void OnClick(EventArgs e)
        {
            base.OnClick(e);

            if (m_menuItemIndex == -1)
                m_clickedItemIndex = -1;
            else
            {
                m_clickedItemIndex = m_menuItemIndex;
                m_menuItemIndex = -1;
            }
        }

5. Example

Project: FOCA
Source File: CheckedButton.cs
protected override void OnClick(EventArgs e)
        {
            base.OnClick(e);
            Checked = !Checked;
        }

6. Example

Project: ArnoldSimulator
Source File: InertButton.cs
protected override void OnClick(EventArgs e)
		{
			if (RepeatClick && !(e is RepeatClickEventArgs))
				return;

			base.OnClick (e);
		}

7. Example

Project: Unity-WinForms
Source File: Button.cs
public void PerformClick()
        {
            OnClick(EventArgs.Empty);
        }

8. Example

Project: Nexus-Mod-Manager
Source File: DetailsButton.cs
protected override void OnClick(EventArgs e)
		{
			ImageIndex = (ImageIndex + 2) % 4;
			m_intTextIndex = (m_intTextIndex + 1) % 2;
			Text = m_strText[m_intTextIndex];
			base.OnClick(e);
		}

9. Example

Project: ynoteclassic
Source File: InertButton.cs
protected override void OnClick(EventArgs e)
        {
            if (RepeatClick && !(e is RepeatClickEventArgs))
                return;

            base.OnClick(e);
        }

10. Example

Project: SquareOne
Source File: InertButton.cs
protected override void OnClick(EventArgs e)
        {
            if (RepeatClick && !(e is RepeatClickEventArgs))
                return;

            base.OnClick (e);
        }

11. Example

Project: xenadmin
Source File: CommandButton.cs
protected override void OnClick(EventArgs e)
        {
            if (Enabled)
            {
                _command.Execute();
            }
            base.OnClick(e);
        }

12. Example

Project: fomm
Source File: SplitButton.cs
protected override void OnClick(EventArgs e)
    {
      if (!m_booShowSplit)
      {
        base.OnClick(e);
        return;
      }

      if (m_tsiLastPressedButton != null)
      {
        m_tsiLastPressedButton.PerformClick();
      }
    }

13. Example

Project: xenadmin
Source File: DropDownButton.cs
protected override void OnClick(EventArgs e)
        {
            base.OnClick(e);

            if (_contextMenuStrip != null && !_ignoreNextClick)
            {
                _contextMenuStrip.Show(this, new Point(0, Height), ToolStripDropDownDirection.Default);
            }

            _ignoreNextClick = false;
        }

14. Example

Project: NFirmwareEditor
Source File: MenuButton.cs
protected override void OnClick(EventArgs e)
		{
			base.OnClick(e);

			if (m_menu == null) return;
			if (Parent != null) Parent.Focus();

			m_menu.Show(this, new Point(1, Height));
			m_menu.Focus();
		}

15. Example

Project: ares
Source File: ColorPaletteButton.cs
protected override void OnMouseUp(MouseEventArgs mevent) {

            if (ContextMenuStrip == null || !ContextMenuStrip.Visible) {
                SetButtonDrawState();
                if (Bounds.Contains(Parent.PointToClient(Cursor.Position)) && !dropDownRectangle.Contains(mevent.Location)) {
                    OnClick(new EventArgs());
                }
            }
        }

16. Example

Project: gitextensions
Source File: SplitButton.cs
protected override void OnMouseUp(MouseEventArgs mevent)
        {
            if (!showSplit)
            {
                base.OnMouseUp(mevent);
                return;
            }

            // if the right button was released inside the button
            if (mevent.Button == MouseButtons.Right && ClientRectangle.Contains(mevent.Location) && !isSplitMenuVisible)
            {
                ShowContextMenuStrip();
            }
            else if (m_SplitMenuStrip == null && m_SplitMenu == null || !isSplitMenuVisible)
            {
                SetButtonDrawState();

                if (ClientRectangle.Contains(mevent.Location) && !dropDownRectangle.Contains(mevent.Location))
                {
                    OnClick(new EventArgs());
                }
            }
        }

17. Example

Project: ares
Source File: SplitButton.cs
protected override void OnMouseUp(MouseEventArgs mevent) {
            if (!showSplit) {
                base.OnMouseUp(mevent);
                return;
            }

            if (ContextMenuStrip == null || !ContextMenuStrip.Visible) {
                SetButtonDrawState();
                if (Bounds.Contains(Parent.PointToClient(Cursor.Position)) && !dropDownRectangle.Contains(mevent.Location)) {
                    OnClick(new EventArgs());
                }
            }
        }

18. Example

Project: ATF
Source File: SplitButton.cs
protected override void OnMouseUp(MouseEventArgs mevent)
        {
            if (!m_showSplit)
            {
                base.OnMouseUp(mevent);
                return;
            }

            if (ContextMenuStrip == null || !ContextMenuStrip.Visible)
            {
                SetButtonDrawState();
                if (Bounds.Contains(Parent.PointToClient(Cursor.Position)) &&
                    !m_dropDownRectangle.Contains(mevent.Location))
                {
                    OnClick(new EventArgs());
                }
            }
        }

19. Example

Project: bdhero
Source File: SplitButton.cs
protected override void OnMouseUp(MouseEventArgs mevent)
        {
            if (!showSplit)
            {
                base.OnMouseUp(mevent);
                return;
            }

            // if the right button was released inside the button
            if (mevent.Button == MouseButtons.Right && ClientRectangle.Contains(mevent.Location) && !isSplitMenuVisible)
            {
                ShowContextMenuStrip();
            }
            else if (m_SplitMenuStrip == null && m_SplitMenu == null || !isSplitMenuVisible)
            {
                SetButtonDrawState();

                if (ClientRectangle.Contains(mevent.Location) && !dropDownRectangle.Contains(mevent.Location))
                {
                    OnClick(new EventArgs());
                }
            }
        }

20. Example

Project: SharpBoot
Source File: SplitButton.cs
protected override void OnMouseUp(MouseEventArgs mevent)
        {
            if (!showSplit)
            {
                base.OnMouseUp(mevent);
                return;
            }

            // if the right button was released inside the button
            if (mevent.Button == MouseButtons.Right && ClientRectangle.Contains(mevent.Location) && !isSplitMenuVisible)
            {
                ShowContextMenuStrip();
            }
            else if (m_SplitMenuStrip == null && m_SplitMenu == null || !isSplitMenuVisible)
            {
                SetButtonDrawState();

                if (ClientRectangle.Contains(mevent.Location) && !dropDownRectangle.Contains(mevent.Location))
                {
                    OnClick(new EventArgs());
                }
            }
        }

21. Example

Project: chummer5a
Source File: SplitButton.cs
protected override void OnMouseUp(MouseEventArgs mevent)
    {
        if (!_showSplit)
        {
            base.OnMouseUp(mevent);
            return;
        }

        // if the right button was released inside the button
        if (mevent.Button == MouseButtons.Right && ClientRectangle.Contains(mevent.Location) && !_isSplitMenuVisible)
        {
            ShowContextMenuStrip();
        }
        else if (m_SplitMenuStrip == null && m_SplitMenu == null || !_isSplitMenuVisible)
        {
            SetButtonDrawState();

            if (ClientRectangle.Contains(mevent.Location) && !_dropDownRectangle.Contains(mevent.Location))
            {
                OnClick(new EventArgs());
            }
        }
    }