Re: Getting 'mouseMoved' events
Re: Getting 'mouseMoved' events
- Subject: Re: Getting 'mouseMoved' events
- From: Matt Neuburg <email@hidden>
- Date: Tue, 21 May 2002 13:33:51 -0700
On Mon, 20 May 2002 16:03:30 -0700, James Pengra <email@hidden> said:
>
I have an NSView in which I utilize mouseDown events and would
>
also like to track the mouse cursor using mouseMoved events. I send
>
the message [myWindow setAcceptsMouseMovedEvents:YES]; before looking
>
for mouse movement, but the procedure -(void)mouseMoved:(NSEvent
>
*)event never gets called. However, mouseDown gets called every
>
time I click in the View.
The fact that you talk about mouseDown in this note makes me wonder whether
your question is about tracking the mouse while it is down. If note, ignore
this reply. If so, note that those are NOT mouseMoved events; you have to
track them in the mouseDown event (essentially, you drive a little event
loop until the mouse is not longer down). The documentation is very good on
this; there's a splendid example showing exactly how to do it. m.
--
matt neuburg, phd = email@hidden,
http://www.tidbits.com/matt
pantes gar anthropoi tou eidenai oregontai phusei
Subscribe to TidBITS! It's free and smart.
http://www.tidbits.com/
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.