On Jan 15, 2010, at 14:19, David Blanton wrote:

> The solution was to override trackKnob and in it set a flag that scrolling 
> was in play.  Then in my drawRect I check the flag to do appropriate 
> scrolling.  Then in coming back from [super trackKnob] I knw scrolling is 
> done so I can clear the flag;

Does this deal with the case where the view is scrolled with the mouse scroll 
wheel instead of by dragging the scroller thumb?

If what you really need to know is *that* your view has been scrolled, rather 
than *how* your view has been scrolled, you can also do it by registering to 
receive bounds-changed notifications from the scroll view's clip view.

(Well, I think it's the clip view bounds that change. I haven't looked at this 
recently, and my head always hurts when I try to figure which coordinate system 
is the one getting changed by the scrolling. Trial and error FTW. :) )

Keep in mind that views don't generate frame- or bounds-changed notifications 
by default -- you have to tell them to do so.


_______________________________________________

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