SDG Toolkit

SdgMouseEventArgs.Button Property

Gets the mouse buttons depressed in this mouse event

public System.Windows.Forms.MouseButtons Button {get;}

Remarks

Please note that the mouse move event returns all mouse buttons that are current pressed. The mouse down and mouse up events only provide the mouse button which raised that event. This coincides with the .NET mouse event standards. For the mouse move events it is advisable to use the & operator to determine if a particular mouse button has been pressed.

Example

C# Eg., if ((e.Button & MouseButtons.Left) > 0) {}

C# Eg., if (e.Button == MouseButtons.Left) {}

See Also

SdgMouseEventArgs Class | Sdgt Namespace