Re: Mouse movement and Edges of screen
Re: Mouse movement and Edges of screen
- Subject: Re: Mouse movement and Edges of screen
- From: Ali Ozer <email@hidden>
- Date: Sun, 22 Jul 2001 01:24:48 -0700
NSEvent also provides this:
/* these messages are valid for scroll wheel events and mouse move/drag
events */
- (float)deltaX;
- (float)deltaY;
Ali
On Saturday, July 21, 2001, at 09:26 , Kenneth C. Dyke wrote:
On Saturday, July 21, 2001, at 09:05 PM, Andreas Monitzer wrote:
On Sunday, July 22, 2001, at 04:58 , R. Eranki wrote:
How can I determine where the user is trying to move his mouse when
it's at
the edge of the screen, -or- how can I force the mouse into the
center of
the screen?
Maybe you should try using HIDManager.
Actually, there's an easier way than that...
From CGDirectDisplay.h.
void CGGetLastMouseDelta( CGMouseDelta * deltaX, CGMouseDelta *
deltaY );
If you call this every time you receive a mouse moved event, you can
get back the raw mouse deltas before the mouse was pinned to the edge
of the screen. There are some other useful functions defined in
CGRemoteOperation.h that you may also find useful.
-Ken