On 14 Aug, 2013, at 10:03 PM, Steve Mills <smi...@makemusic.com> wrote:
> 
> There most certainly is not a deeper issue with my code. Run this and you'll 
> see for yourself:
> 
> -(IBAction) openDocument:(id)sender
> {
>       NSOpenPanel*                    p = [NSOpenPanel openPanel];
>       
>       if([p runModal] == NSFileHandlingPanelOKButton) {
>               [p orderOut:self];
>               // Simulate code that takes 5 seconds to open a document:
>               sleep(5);
>       }
> }
> 

What does that code end up doing? Not order the window out, not order it out 
until after the 5 seconds have elapsed or what? Not much of an OSX guy but 
something similar on iOS, with a 5 second piece of work on the main thread, 
would stop the UI animating until it returned control to the runloop. 

_______________________________________________

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

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

Reply via email to