Microsoft DirectX 9.0 SDK Update (October 2004)

MouseState Structure

Language:

Note: This documentation is preliminary and is subject to change.

Describes the state of a mouse device that has up to four buttons, or another device that is being accessed as if it were a mouse device. This structure is used with the Inputdevice9Getdevicestate method.

Definition

Visual Basic .NET Public Structure MouseState
C# public struct MouseState
Managed C++ public __value struct MouseState
JScript .NET In JScript .NET, you can use structures, but you cannot define your own.

Members Table

Method Description
GetMouseButtons Array of buttons. The high-order bit of the byte is set if the corresponding button is down.
MouseState Initializes a new instance of the object.
ToString Obtains a string representation of the current instance.
Property Description
X X-axis.
Y Y-axis.
Z Z-axis, typically a wheel. If the mouse does not have a z-axis, the value is 0.

Structure Information

Namespace Microsoft.DirectX.DirectInput
Assembly Microsoft.DirectX.DirectInput (microsoft.directx.directinput.dll)
Strong Name Microsoft.DirectX.DirectInput,  Version=1.0.2902.0,  Culture=neutral,  PublicKeyToken=31bf3856ad364e35

© 2004 Microsoft Corporation. All rights reserved. Terms of use.

Feedback? Please provide us with your comments on this topic.
For more help, visit the DirectX Developer Center