• 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: Multithreaded NSView:setNeedsDisplay:
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Multithreaded NSView:setNeedsDisplay:


  • Subject: Re: Multithreaded NSView:setNeedsDisplay:
  • From: Scott Anguish <email@hidden>
  • Date: Tue, 4 Dec 2007 03:30:00 -0500

[view performSelectorOnMainThread:@selector(redisplay) withObject:YES waitUntilDone:NO];

But this is ugly. Is there a better way? Bummer that setNeedsDisplay: is not threadsafe. Bummer that it requires an argument at all...


I had answered this off-list, but just to reiterate

this is probably the best way to do this

[view performSelectorOnMainThread:@selector(redisplay) withObject:nil waitUntilDone:NO];

and have the redisplay stub method as part of your view subclass.





_______________________________________________

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


References: 
 >Multithreaded NSView:setNeedsDisplay: (From: Rony Kubat <email@hidden>)

  • Prev by Date: Re: Help diagnosing memory problem
  • Next by Date: What to pack to deliver?
  • Previous by thread: Multithreaded NSView:setNeedsDisplay:
  • Next by thread: What to pack to deliver?
  • Index(es):
    • Date
    • Thread