MOUSEHOOKSTRUCTEX structure

Contains information about a mouse event passed to a WH_MOUSE hook procedure, MouseProc.

This is an extension of the MOUSEHOOKSTRUCT structure that includes information about wheel movement or the use of the X button.

Syntax


typedef struct tagMOUSEHOOKSTRUCTEX {
  MOUSEHOOKSTRUCT MOUSEHOOKSTRUCT;
  DWORD           mouseData;
} MOUSEHOOKSTRUCTEX, *PMOUSEHOOKSTRUCTEX, *LPMOUSEHOOKSTRUCTEX;

Members

MOUSEHOOKSTRUCT

Type: MOUSEHOOKSTRUCT

The members of a MOUSEHOOKSTRUCT structure make up the first part of this structure.

mouseData

Type: DWORD

If the message is WM_MOUSEWHEEL, the HIWORD of this member is the wheel delta. The LOWORD is undefined and reserved. A positive value indicates that the wheel was rotated forward, away from the user; a negative value indicates that the wheel was rotated backward, toward the user. One wheel click is defined as WHEEL_DELTA, which is 120.

If the message is WM_XBUTTONDOWN, WM_XBUTTONUP, WM_XBUTTONDBLCLK, WM_NCXBUTTONDOWN, WM_NCXBUTTONUP, or WM_NCXBUTTONDBLCLK, the HIWORD of mouseData specifies which X button was pressed or released, and the LOWORD is undefined and reserved. This member can be one or more of the following values. Otherwise, mouseData is not used.

ValueMeaning
XBUTTON1
0x0001

The first X button was pressed or released.

XBUTTON2
0x0002

The second X button was pressed or released.

 

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Winuser.h (include Windows.h)

See also

Reference
MouseProc
MOUSEHOOKSTRUCT
WM_MOUSEWHEEL
WM_XBUTTONDOWN
WM_XBUTTONUP
WM_XBUTTONDBLCLK
WM_NCXBUTTONDOWN
WM_NCXBUTTONUP
WM_NCXBUTTONDBLCLK
Conceptual
Hooks

 

 

Community Additions

ADD
Show:
© 2014 Microsoft