Message-ID: <362FD88C.E4A27845@montana.com> Date: Thu, 22 Oct 1998 19:14:52 -0600 From: bowman X-Mailer: Mozilla 4.5b2 [en] (Win95; I) X-Accept-Language: en MIME-Version: 1.0 To: djgpp AT delorie DOT com Subject: Re: My mousecommitted suicide addendum. References: <70o4t0$l02$1 AT nnrp1 DOT dejanews DOT com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Reply-To: djgpp AT delorie DOT com oh, yeah, the initialization and close functions. I lump your mouse_detect and mouse_show into one call to match the gpm stuff, but it is the same. NOTE: you are checking mouse_detect to see if you have a valid mouse driver? I probably should also be doing a r.x.ax & 0x0ffff on the first return. int Gpm_Open(Gpm_Connect* conn, int flag) { union REGS r; r.x.ax = 0x00; int86(0x33, &r, &r); if (r.x.ax == 0) // no mouse handler return -1; r.x.ax = 0x01; int86(0x33, &r, &r); // display the mouse cursor gpm_flag = 1; return 0; } int Gpm_Close(void) { union REGS r; r.x.ax = 0x02; // remove the mouse cursor int86(0x33, &r, &r); return 0; }