ITaskbarList2::MarkFullscreenWindow method (shobjidl_core.h)

Marks a window as full-screen.

Syntax

HRESULT MarkFullscreenWindow(
  [in] HWND hwnd,
  [in] BOOL fFullscreen
);

Parameters

[in] hwnd

Type: HWND

The handle of the window to be marked.

[in] fFullscreen

Type: BOOL

A Boolean value marking the desired full-screen status of the window.

Return value

Type: HRESULT

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Remarks

Setting the value of fFullscreen to TRUE, the Shell treats this window as a full-screen window, and the taskbar is moved to the bottom of the z-order when this window is active. Setting the value of fFullscreen to FALSE removes the full-screen marking, but does not cause the Shell to treat the window as though it were definitely not full-screen. With a FALSE fFullscreen value, the Shell depends on its automatic detection facility to specify how the window should be treated, possibly still flagging the window as full-screen.

Since Windows 7, call SetProp(hwnd, L”NonRudeHWND”, reinterpret_cast<HANDLE>(TRUE)) before showing a window to indicate to the Shell that the window should not be treated as full-screen. This ensures the taskbar does not adjust itself to be below the window in z-order. This is similar to ITaskbarList2::MarkFullscreenWindow(FALSE) except the Shell will not fallback to its automatic detection facility and will not treat the window as full-screen.

Requirements

Requirement Value
Minimum supported client Windows XP [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Target Platform Windows
Header shobjidl_core.h (include Shobjidl.h)
DLL Shell32.dll

See also

ITaskbarList

ITaskbarList2

SetPropA

SetPropW