Re: Confused about NSTrackingAreas with autoscroll [WORKAROUND]
Re: Confused about NSTrackingAreas with autoscroll [WORKAROUND]
- Subject: Re: Confused about NSTrackingAreas with autoscroll [WORKAROUND]
- From: Luke Evans <email@hidden>
- Date: Thu, 5 Feb 2009 10:59:15 -0800
Hi Corbin. Thanks for the note.
Well, the trouble is, if you are consuming the event loop, then you
need to dispatch things.
Have you seen: http://developer.apple.com/samplecode/PhotoSearch/
?
Yes, I studied this before I started and used the patterns in there.
The cell consumes the event loop and dispatches events. Look at the
code via http://developer.apple.com/samplecode/PhotoSearch/listing9.html
ie:
if ([theEvent type] == NSMouseEntered || [theEvent type] ==
NSMouseExited) { [NSApp sendEvent:theEvent]; }
But do please log a bug; at worst, we can clarify with better
documentation, or make it easier (somehow) with new API.
corbin
Absolutely. I was dispatching NSMouseEntered, NSMouseExited and
NSLeftMouseDrag.
This was all working perfectly until I added code to do the
autoscrolling. I used NSPeriodic for this (which I also tried
dispatching, seeing as I was consuming it), and had the appropriate
call to scroll the view on receipt of the periodic events. At that
point I found the tracking areas to be out of place with respect to
the displacement of the view.
-- lwe
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden