home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 7 / 07.iso / c / c100 / 1.ddi / MOUSE.ZIP / M_CONDIT.C < prev    next >
Encoding:
C/C++ Source or Header  |  1990-07-11  |  661 b   |  27 lines

  1. /*
  2.  *    m_conditional.c
  3.  *
  4.  *    Public Domain (p) March 1990 By Rodney Loos
  5.  *    Syntax modified by S. Sampson
  6.  */
  7.  
  8. #include <dos.h>
  9. #include "mouse.h"
  10.  
  11. /*
  12.  *    Function to hide the mouse if it is in the region
  13.  *    when this function is called.  Your program must call
  14.  *    m_display(ON) to enable the cursor again.
  15.  */
  16.  
  17. void m_conditional(int ux, int uy, int lx, int ly)
  18. {
  19.     _AX = 16;        /* mouse function 16          */
  20.     _CX = ux;        /* upper x screen coordinates */
  21.     _DX = uy;        /* upper y screen coordinates */
  22.     _SI = lx;        /* lower x screen coordinates */
  23.     _DI = ly;        /* lower y screen coordinates */
  24.  
  25.     geninterrupt(0x33);    /* mouse interrupt */
  26. }
  27.