Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Zortech C++ Language Reference - msm_signal http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
                                msm_signal

   Usage
   #include <msmouse.h>
   void  msm_signal(unsigned mask, void(*func) (unsigned  mask,  unsigned
   state, unsigned curposx, unsigned curposy), void *stack);

   Description
   Sets  up a user-defined subroutine input mask. Used to set a  function
   to be called at interrupt level whenever there is input available from
   the mouse.

   All  the usual caveats apply to the interrupt service  routine.  Using
   this function is not for the faint-hearted. On input mask defines when
   to call the user function (1 means yes):

   Bit 0:mouse moved
   Bit 1:left button is pressed
   Bit 2:left button is released
   Bit 3:right button is pressed
   Bit 4:right button is released
   Bit 5:middle button is pressed
   Bit 6:middle button is released

   Other  bits  are  not used. The parameter func is  a  pointer  to  the
   application-defined interrupt service routine to call whenever a mouse
   button  is pressed or released, or the mouse moves, according  to  the
   bits  in  mask. The parameter stack contains the value  to  set  stack
   pointer to when func is called. Should point just past end of an  area
   that is at least 256 bytes long. When func is called, it is passed the
   following:

   mask  - Event that occurred is indicated with the bit set  as  defined
   above.
   state - If button event, this is the button number of the button  that
   changed (0 = left, 1 = right, 2 = middle).
   curposx, curposy - Current mouse position.


Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson