Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sdd.hp.com!mips!cs.uoregon.edu!ogicse!qiclab!percy!tektronix!reed!witt From: witt@reed.UUCP (Jeffrey Witt) Newsgroups: comp.sys.mac.programmer Subject: Re: FAQ - how do I change the mouse's location? Summary: how to chang ethe mouse location Keywords: mouse location Message-ID: <16327@reed.UUCP> Date: 15 Apr 91 21:04:09 GMT References: <1991Apr15.150330.3085@hubcap.clemson.edu> Reply-To: witt@reed.UUCP (Jeffrey Witt) Organization: Reed College, Portland OR Lines: 33 In article <1991Apr15.150330.3085@hubcap.clemson.edu> jcocon@hubcap.clemson.edu (james c oconnor) writes: >Hi - I'm writing a stack which is to be used by complete novices >who won't go through "Introduction to the Mac", so they will know >very little of the interface. In response, I've made my fields >select themselves when the mouse enters their rectangle. The problem Tisk. tisk, tisk. >[question on how to change the mouse location] The technique you describe is an Apple No-No (tm). However, if you really want to change the mouse location, try this: Procedure SetMouse(where: point); Const RAWMOUSE = $82c; MTEMP = $828; CRSRNEW = $8ce; Begin LocalToGlobal(where); ptrL(RAWMOUSE)^:= where; ptrL(MTEMP)^:= where; ptrB(CRSRNEW)^:= byte($01); End; > >Thanks, >Jim Note again that changing the mouse location (and messing with system globals, for that matter) is considered hostile behavior. Jeff Witt witt@reed.UUCP