On Feb 3, 2009, at 14:14, Luke Evans wrote:

This really looks like the tracking areas established on the view when the original mouse down event (that starts the drag) are cached and remain in play during the drag operation.
Can anyone confirm if this is the case?

I've never seen anything to support this, though it may be so. If you want to be certain, I guess you're going to have to log or otherwise capture the addresses of your tracking area objects when you create them, and compare them with the owning tracking area that you can get out of the NSEvent when the relevant event (mouseEntered?) occurs.

Overtly updating the tracking areas after calling '-autoscroll:' by directly calling -updateTrackingAreas on the table, does not seem to affect what tracking areas fire events so long as I remain in the drag. Everything returns to normal as soon as the drag operation completes.

The evidence you've cited so far only points to the tracking area being in the "wrong" place, not necessarily to it being the wrong tracking area. I'm inclined to think that the misbehavior is an artifact of view coordinate systems. If the coordinates of a tracking area are specified in local coordinates of the table view, then the actual position in the window is affected by the relationship of the table view bounds to its frame; of the table view frame to the clip view bounds; of the clip view bounds to the clip view frame; of the clip view frame to the scroll view bounds; of the scroll view bounds to the scroll view frame; of the scroll view frame to its superview bounds (probably the window content view).

Out of those, the clip view bounds and frame are the ones that will change outside your control. And, one or other must change in the middle of your code, when you call autoscroll. And, it's not totally impossible that the table view is changing its own bounds origin (though that seems unlikely).

I have to admit, on the couple of occasions when I needed to figure out coordinate systems around autoscroll, I did not have the fortitude to discover the why of it, I just tried adding and subtracting offsets till it seemed to work, then moved on.

_______________________________________________

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