home *** CD-ROM | disk | FTP | other *** search
- /******************************************************************************
- * Simple routines to set up a program as TSR, by hooking the keyboard *
- * interrupt locally and testing the scancodes against given scancode hot key. *
- * This module was tested in TINY model only. *
- * *
- * Written By Gershon Elber, June 1989 *
- ******************************************************************************/
-
- /* Scan code is specified as follows: */
- /* highbyte - scan code of keyboard key (as given to interrupt 9). */
- /* lowbyte - shift mask: Right shift - bit 1, Left shift - bit 2, */
- /* Ctl - bit2, Atl - bit 3. */
- /* Func is the function to execute as the TSR process. */
- /* Returns: 0 if O.k., 1 if already installed, 2 install failed. */
- int HookKbdInterrupt(void (*Func)(), unsigned int ScanCode);
-
- /* If HookKbdInterrupt returns 1 (already installed), _InstalledTSRSegment */
- /* is set to the installed version segment, so variables in the installed */
- /* version may be changed (remember offset are the same!). */
- extern unsigned int InstalledTSRSegment;