Jump to content

WinLockPointerUpdate: Difference between revisions

From EDM2
Created page with "This function is specific to OS/2 Version 2.1 or higher. This function causes the mouse pointer to change into the symbol described by {{hp1|hptrNew}} for the period of time indicated by ulTimeInterval. ==Syntax==  WinLockPointerUpdate(hwndDesktop, hptrNew, ulTimeInterval) ==Parameters== ;hwndDesktop (HWND) - Input : Handle to the desktop window. ;hptrNew (HPOINTER) - Input : Pointer handle to be displayed. ;ulTimeInterval (ULONG) - Input : Time interval...."
 
No edit summary
 
Line 1: Line 1:
This function is specific to OS/2 Version 2.1 or higher.
This function is specific to OS/2 Version 2.1 or higher.


This function causes the mouse pointer to change into the symbol described by {{hp1|hptrNew}} for the period of time indicated by ulTimeInterval.
This function causes the mouse pointer to change into the symbol described by hptrNew for the period of time indicated by ulTimeInterval.


==Syntax==
==Syntax==

Latest revision as of 17:24, 9 April 2025

This function is specific to OS/2 Version 2.1 or higher.

This function causes the mouse pointer to change into the symbol described by hptrNew for the period of time indicated by ulTimeInterval.

Syntax

 WinLockPointerUpdate(hwndDesktop, hptrNew, ulTimeInterval)

Parameters

hwndDesktop (HWND) - Input
Handle to the desktop window.
hptrNew (HPOINTER) - Input
Pointer handle to be displayed.
ulTimeInterval (ULONG) - Input
Time interval.
The time (0 to 65,535ms) during which changes to the mouse pointer shape will be locked out.

Returns

rc (BOOL) - returns
Success indicator.
TRUE
Successful.
FALSE
An error occurred.

Remarks

The mouse remains fully functional during the lock time, however the pointer shape is not updated. This function can be used to convey visual feedback to the user, that some mouse action has been recognized. For example, that a gesture has been recognized from the last few mouse movements.

Example Code

#define INCL_WINPOINTERS /* Or use INCL_WIN, INCL_PM, */
#include <os2.h>

HWND        hwndDesktop;     /*  Handle to the desktop window. */
HPOINTER    hptrNew;         /*  Pointer handle to be displayed. */
ULONG       ulTimeInterval;  /*  Time interval. */
BOOL        rc;              /*  Success indicator. */

rc = WinLockPointerUpdate(hwndDesktop, hptrNew,
       ulTimeInterval);