WinCheckInput: Difference between revisions
Appearance
Created page with "This function is specific to OS/2 Version 2.1 or higher. This function is used in conjunction with the MsgInputHook hook to input simulated events into the Presentation Manag..." |
|||
(One intermediate revision by one other user not shown) | |||
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 is used in conjunction with the MsgInputHook hook to input simulated events into the Presentation Manager input processing system. | This function is used in conjunction with the MsgInputHook hook to input simulated events into the Presentation Manager input processing system. | ||
==Syntax== | ==Syntax== | ||
Line 7: | Line 7: | ||
==Parameters== | ==Parameters== | ||
;hab (HAB) - input | ;hab (HAB) - input:The application anchor block. | ||
:The application anchor block. | |||
==Returns== | ==Returns== | ||
;rc (BOOL) - returns | ;rc (BOOL) - returns | ||
:Return code. | :Return code. | ||
: | ::TRUE - The system checked for mouse and keyboard input. | ||
::FALSE - An error occurred. | |||
: | |||
==Remarks== | ==Remarks== | ||
This function must be called whenever an application injects simulated mouse or keyboard events using MsgInputHook, otherwise there is no guarantee when those simulated events will occur. It forces the Presentation Manager input processing system to wake up and take a look at all possible sources of input events: the MsgInputHook hook, the JournalPlaybackHook hook, and the Presentation Manager input queue that contains normal mouse and keyboard events. | This function must be called whenever an application injects simulated mouse or keyboard events using MsgInputHook, otherwise there is no guarantee when those simulated events will occur. It forces the Presentation Manager input processing system to wake up and take a look at all possible sources of input events: the MsgInputHook hook, the JournalPlaybackHook hook, and the Presentation Manager input queue that contains normal mouse and keyboard events. | ||
==Example Code== | ==Example Code== | ||
Definition | Definition | ||
<pre> | <pre> | ||
Line 37: | Line 31: | ||
==Related Functions== | ==Related Functions== | ||
* MsgInputHook | * [[MsgInputHook]] | ||
[[Category:Win]] | [[Category:Win]] |
Latest revision as of 19:08, 14 May 2025
This function is specific to OS/2 Version 2.1 or higher.
This function is used in conjunction with the MsgInputHook hook to input simulated events into the Presentation Manager input processing system.
Syntax
WinCheckInput(hab)
Parameters
- hab (HAB) - input
- The application anchor block.
Returns
- rc (BOOL) - returns
- Return code.
- TRUE - The system checked for mouse and keyboard input.
- FALSE - An error occurred.
Remarks
This function must be called whenever an application injects simulated mouse or keyboard events using MsgInputHook, otherwise there is no guarantee when those simulated events will occur. It forces the Presentation Manager input processing system to wake up and take a look at all possible sources of input events: the MsgInputHook hook, the JournalPlaybackHook hook, and the Presentation Manager input queue that contains normal mouse and keyboard events.
Example Code
Definition
#define INCL_WININPUT /* Or use INCL_WIN, INCL_PM, */ #include <os2.h> HAB hab; /* The application anchor block. */ BOOL rc; /* Return code. */ rc = WinCheckInput(hab);