Article View: rec.games.programmer
Article #770Mouse Event Handler (simple solution?)
From: Erik Johnson
Date: Tue, 18 Aug 1992 14:28
Date: Tue, 18 Aug 1992 14:28
29 lines
1723 bytes
1723 bytes
I figure there must be plenty of you who have done this before...
I am trying to set up my own event handler for the mouse (Microsoft),
and I am nearly successful.
At the base level I simply want to set a few global variables that convey
the current mouse position. Right now I am simply trying to get a routine
that does nothing but return, to work. Here is what I am doing:
1 Using INT 0x33 AX=0x14 to set my routine into action
2a If my routine consists of a RET and nothing else, the
routine jumps to the beginning of main(), so I believe
that RET is not the proper way to return.
2b If I use IRET, then my machine just plain locks.
What am I missing, must you do something more before doing an IRET (or
is this even correct)? As an alternate method, I have tried using C
routines of both type Void() and type Void Interrupt () for the handler,
with results identical to above.
Turbo Debugger shows that my driver code is being executed, so the install
is successful. (I am using Borland C++ 3.1 and Turbo Assembler).
When the program runs it does a series of printf's to the screen, so it
is quite possible that we are interrupting a DOS function.
Thank you for your time (even more so if you can help),
Erik R Johnson erik@microware.com
Technical Details
Message-ID:
<1992Aug18.142813.4814@microware.com>Path:
arc1-ca.pugleaf.net!sparky!uunet!mcrware!erikShow Full Headers
Complete Article Headers
Newsgroups: rec.games.programmer Path: arc1-ca.pugleaf.net!sparky!uunet!mcrware!erik From: erik@microware.com (Erik Johnson) Subject: Mouse Event Handler (simple solution?) Message-ID: <1992Aug18.142813.4814@microware.com> Sender: news@microware.com Nntp-Posting-Host: zeppo Organization: Microware Systems Corp., Des Moines, Iowa Date: Tue, 18 Aug 1992 14:28:13 GMT Lines: 29