MouseButtonState Enumeration
Collapse the table of content
Expand the table of content

MouseButtonState Enumeration


Specifies the possible states of a mouse button.

Namespace:   System.Windows.Input
Assembly:  PresentationCore (in PresentationCore.dll)

public enum MouseButtonState

Member nameDescription

The button is pressed.


The button is released.

The MouseButtonState enumeration specifies constants which correlate to the state of a mouse button.

Legacy Code Example

The following example shows a mouse event handler that determines which buttons are currently pressed by checking the button state of each mouse button.

Code snippet is not found. Confirm that the code snippet name 'mousesnippetsample' is correct.

.NET Framework
Available since 3.0
Return to top
© 2015 Microsoft