On 2008-06-09 19:27:00 -0700, Adam R.Maxwell <[EMAIL PROTECTED]> said:

> On 2008-06-09 18:41:23 -0700, "Colin A. Smith" <[EMAIL PROTECTED]> said:
> 
>> On Jun 9, 2008, at 17:36, Adam R. Maxwell wrote:
>> 
>>> Clever :).  Does it help at all to do something like [[OFMessageQueue
>>> mainQueue] queueSelectorOnce:... for rebuildTrackingRects?  That might
>>> be more future-proof.
>> 
>> I think that might help a bit but is still going to allow
>> rebuildTrackingRects calls while a user is actively scrolling.   While
>> rebuildTrackingRects is running, nothing else on the main thread can
>> run and processing scroll events is significantly poorer. The worst
>> case, in which scroll events and rebuildTrackingRects, would still be
>> possible.
> 
> Right; I forgot that OFMessageQueue is based on NSConditionLock instead
> of NSRunloop :/.  However, if you used something like this
> 
> - (void)scheduleRebuildTrackingRects
> {
>       if (!_scheduledRebuildTrackingRects) {
>               [self performSelector:@selector(rebuildTrackingRects) 
> withObject:nil
> afterDelay:0 inModes:[NSArray arrayWithObject:NSDefaultRunLoopMode];
>               _scheduledRebuildTrackingRects = YES;
>       }
> }
> 
> - (void)rebuildTrackingRects
> {
>       _scheduledRebuildTrackingRects = NO;
>       ...
> }
> 
> then it wouldn't rebuild tracking rects while in
> NSEventTrackingRunLoopMode, which is what the scrollview should be
> using (hypothetically, at least; I use this trick in FileView to deal
> with icon scale changes).

<sigh> that won't quite work either, although it partly works with a 
non-zero delay.  Trackpad scrolling apparently uses scrollWheel: and 
runs the runloop in the default mode.  It's not tracking a control, so 
that sort of makes sense...but I think it's inconsistent.



-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
Bibdesk-develop mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bibdesk-develop

Reply via email to