Well, it's beyond any doubt in my mind now: my view's tracking areas are not adjusted when I'm performing a drag operation and during this operation an autoScroll is performed (in response to the user dragging outside the visible rect of the view/clipView within the local scrollView).

Calling my own -updateTrackingAreas when I know the autoscroll has occurred does not help at all - I can see the rectangles being constructed with the correct locations, but the view still sends events as if the scroll offsets within the clipView were the same as when the drag started.

Up until now I was relatively happy with my first real sojourn in the land of NSTrackingArea - with the possible exception of finding out that you don't get mouse entered/exited messages when the view scrolls _under_ the mouse (e.g. use of the scroll wheel on the mouse) - but in that case you _do_ get officially called to regenerate tracking areas, so I send my own synthesized events when I generate the new tracking area rectangles.

The situation when in a mouse dragging loop is much more serious though. The eventing concerning tracking area boundaries is totally unreliable, seeing as the view seems to be stuck with the tracking states as they were when the drag started. The mouse dragged messages arrive reliably, and one can perform _immediate_ hit testing on objects for which the tracking areas were intended, but now my view has to know to ignore the dodgy mouseEntered/Exited events which entails having some 'in drag' state distastefully pushed into the view object from the drag loop. Oh well.

I knew I should have stuck with good old fashioned on-the-fly hit testing in the entire view, rather than using these new-fangled tracking area appliances ;-)







_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to