NvtSetDisplayFocus Function  
 
BOOL WINAPI NvtSetDisplayFocus(
  HDISPLAY hDisplay,  
  BOOL bFocus  
);

The NvtSetDisplayFocus function sets or removes the focus from the virtual display. This function should be called when the display window receives or loses focus.

Parameters

hDisplay
Handle to the virtual display.
bFocus
A boolean flag which specifies that the display should receive or lose focus.

Return Value

If the function succeeds, the return value is non-zero. If the function fails, it returns zero.

Remarks

When the virtual display receives focus, it updates the current cursor position and displays the caret. When the display loses focus, the caret is hidden. This function should be called in response to the display window receiving the WM_SETFOCUS and WM_KILLFOCUS messages.

Requirements

Minimum Desktop Platform: Windows 7 (Service Pack 1)
Minimum Server Platform: Windows Server 2008 R2 (Service Pack 1)
Header File: cstools10.h
Import Library: csnvtv10.lib

See Also

NvtUpdateCaret