WM_SHOWWINDOW

2.x

WM_SHOWWINDOW
fShow = (BOOL) wParam;              /* show/hide flag */
fnStatus = LOWORD(lParam);    /* status flag    */

The WM_SHOWWINDOW message is sent to a window when it is about to be hidden or shown. A window is hidden or shown when the ShowWindow function is called; when an overlapped window is maximized or restored; or when an overlapped or pop-up window is minimized or displayed on the screen. When an overlapped window is minimized, all pop-up windows associated with that window are hidden.

Parameters

fShow

Value of wParam. Specifies whether a window is being shown. It is TRUE if the window is being shown; it is FALSE if the window is being hidden.

fnStatus

Value of the low-order word of lParam. Specifies the status of the window being shown. The fnStatus parameter is zero if the message is sent because of a ShowWindow function call; otherwise, fnStatus is one of the following values:

Value Description

SW_PARENTCLOSING Parent window is being minimized, or a pop-up window is being hidden.
SW_PARENTOPENING Parent window is opening (being displayed) or a pop-up window is being shown.

Return Value

An application should return zero if it processes this message.

Comments

The DefWindowProc function hides or shows the window as specified by the message.

The WM_SHOWWINDOW message is not sent under the following circumstances:

When a main window is created with the WS_MAXIMIZE or WS_MINIMIZE style

When the SW_SHOWNORMAL flag is specified in the call to the ShowWindow function

See Also

DefWindowProc, ShowWindow