Re: What should we do if file-opening takes a long time?
Re: What should we do if file-opening takes a long time?
- Subject: Re: What should we do if file-opening takes a long time?
- From: Charles Srstka <email@hidden>
- Date: Sat, 31 Dec 2016 20:03:34 -0600
> On Dec 31, 2016, at 7:35 PM, Graham Cox <email@hidden> wrote:
>
> NSProgress is thread safe and might be useful for this.
One thing to be careful about when using NSProgress with threads is not to bind directly to it from your UI elements, since the updates will come in on the same thread the changes were made on. Either register your observers manually and call the main thread from -observeValue:forKeyPath:ofObject:change:context:, or have your worker thread call the main thread to update the NSProgress object.
Charles
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden