WM_POINTERACTIVATE message

Sent to an inactive window when a primary pointer generates a WM_POINTERDOWN over the window. As long as the message remains unhandled, it travels up the parent window chain until it is reaches the top-level window. Applications can respond to this message to specify whether they wish to be activated.

A window receives this message through its WindowProc function.

#define WM_POINTERACTIVATE             0x024B

Parameters

wParam

Contains the pointer identifier and additional information. Use the following macros to retrieve this information.

GET_POINTERID_WPARAM(wParam): pointer identifier

HIWORD(wParam): hit-test value returned from processing the WM_NCHITTEST message.

lParam

Contains the handle to the top-level window of the window being activated.

Return value

If an application processes this message, it should return one of the values described in the Remarks section.

If the application does not process this message, it should call DefWindowProc.

Remarks

An application can handle this message and return one of the following values to determine how the system processes the activation and the activating input:

  • PA_ACTIVATE
  • PA_NOACTIVATE

It is important to note that, when the user is interacting with the system with multiple simultaneous pointers, the activation opportunity that the WM_POINTERACTIVATE message represents is available to applications only for the first of those pointers. Applications should, therefore, be aware that they may still receive input from pointers while they are inactive.

If the application does not handle this message, DefWindowProc passes the message to the parent window.

Requirements

Requirement Value
Minimum supported client
Windows 8 [desktop apps only]
Minimum supported server
Windows Server 2012 [desktop apps only]
Header
Winuser.h (include Windows.h)

See also

Messages