• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Threads
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Threads


  • Subject: Re: Threads
  • From: Fritz Anderson <email@hidden>
  • Date: Fri, 19 Jul 2013 14:48:26 -0500

On 19 Jul 2013, at 1:56 PM, koko <email@hidden> wrote:

> How can, or can, the -setNeedsDispay:YES be run on a separate thread?

If the documentation doesn't explicitly say a method or class is safe outside the main thread, you can't call it outside the main thread.

Use an NSOperation, or -performSelectorOnMainThread: (you'll have to wrap the call in your own method), or dispatch_[a]sync() to do it on the main thread.

	— F


_______________________________________________

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


  • Follow-Ups:
    • Re: Threads
      • From: koko <email@hidden>
References: 
 >Threads (From: koko <email@hidden>)

  • Prev by Date: Full screen
  • Next by Date: Re: Threads
  • Previous by thread: Threads
  • Next by thread: Re: Threads
  • Index(es):
    • Date
    • Thread