Show / Hide Table of Contents

Class MouseButtonEventArgs

Defines the event data for ButtonDown and ButtonUp events.

Inheritance
Object
EventArgs
MouseEventArgs
MouseButtonEventArgs
Inherited Members
MouseEventArgs.X
MouseEventArgs.Y
MouseEventArgs.Position
MouseEventArgs.Mouse
EventArgs.Empty
Object.ToString()
Object.Equals(Object)
Object.Equals(Object, Object)
Object.ReferenceEquals(Object, Object)
Object.GetHashCode()
Object.GetType()
Object.MemberwiseClone()
Namespace: OpenTK.Input
Assembly: OpenTK.dll
Syntax
public class MouseButtonEventArgs : MouseEventArgs
Remarks

Do not cache instances of this type outside their event handler. If necessary, you can clone an instance using the MouseButtonEventArgs(MouseButtonEventArgs) constructor.

Constructors

MouseButtonEventArgs()

Constructs a new MouseButtonEventArgs instance.

Declaration
public MouseButtonEventArgs()

MouseButtonEventArgs(MouseButtonEventArgs)

Constructs a new MouseButtonEventArgs instance.

Declaration
public MouseButtonEventArgs(MouseButtonEventArgs args)
Parameters
Type Name Description
MouseButtonEventArgs args

The MouseButtonEventArgs instance to clone.

MouseButtonEventArgs(Int32, Int32, MouseButton, Boolean)

Constructs a new MouseButtonEventArgs instance.

Declaration
public MouseButtonEventArgs(int x, int y, MouseButton button, bool pressed)
Parameters
Type Name Description
Int32 x

The X position.

Int32 y

The Y position.

MouseButton button

The mouse button for the event.

Boolean pressed

The current state of the button.

Properties

Button

Gets the MouseButton that triggered this event.

Declaration
public MouseButton Button { get; }
Property Value
Type Description
MouseButton

IsPressed

Gets a System.Boolean representing the state of the mouse button for the event.

Declaration
public bool IsPressed { get; }
Property Value
Type Description
Boolean
In This Article
Back to top Generated by DocFX