Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!uwm.edu!gem.mps.ohio-state.edu!apple!apple.com!chewy From: chewy@apple.com (Paul Snively) Newsgroups: comp.sys.mac.programmer Subject: Re: jGNEfilter question Message-ID: <4952@internal.Apple.COM> Date: 30 Oct 89 17:08:26 GMT References: <6901@hubcap.clemson.edu> Sender: usenet@Apple.COM Organization: Apple Computer, Inc. Lines: 35 In article <6901@hubcap.clemson.edu> mikeoro@hubcap.clemson.edu (Michael K O'Rourke) writes: > It mentions that a pointer to the event > record is in register A1. I tried some assembly in LSC to move the > address to a local variable, but am having problems. > > > The code i tried was : > > Eventrecord *theEvent; > > asm { > move.l theEvent,A1 > } > > When i check theEvent, there is NEVER a mouseDown or mouseUp. (I had a sysbeep > in). I don't really know assembly, so could someone tell me what is wrong > with what i am trying to do? How can i properly get to the eventrecord > so that i may change or modify its contents? Oops. Try "move.l A1,theEvent". In other words, you got the parameters to the move instruction reversed. Don't feel badly; this was a big stumbling block on the 680x0 to me for a long time, since I moved to this family from the Z-80! (Anyone else here remember the mighty Z-80)? __________________________________________________________________________ Just because I work for Apple Computer, Inc. doesn't mean that they believe what I believe or vice-versa. __________________________________________________________________________ C++ -- The language in which only friends can access your private members. __________________________________________________________________________