WM_WINDOWPOSCHANGED

3.1

WM_WINDOWPOSCHANGED
pwp = (const WINDOWPOS FAR*) lParam;    /* structure address          */

The WM_WINDOWPOSCHANGED message is sent to a window whose size, position, or z-order has changed as a result of a call to SetWindowPos or another window-management function.

Parameters

pwp

Value of lParam. Points to a WINDOWPOS data structure that contains information about the window's new size and position. The WINDOWPOS structure has the following form:

typedef struct tagWINDOWPOS { /* wp */
    HWND    hwnd;
    HWND    hwndInsertAfter;
    int     x;
    int     y;
    int     cx;
    int     cy;
    UINT    flags;
} WINDOWPOS;

Return Value

An application should return zero if it processes this message.

Comments

The DefWindowProc function, when it processes the WM_WINDOWPOSCHANGED message, sends the WM_SIZE and WM_MOVE messages to the window. These messages are not sent if an application handles the WM_WINDOWPOSCHANGED message without calling DefWindowProc. It is more efficient to perform any move or size change processing during the WM_WINDOWPOSCHANGED message without calling DefWindowProc.

See Also

WM_MOVE, WM_SIZE, WM_WINDOWPOSCHANGING