• 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: NSTableDataSources and multi-threading
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSTableDataSources and multi-threading


  • Subject: Re: NSTableDataSources and multi-threading
  • From: Dustin Voss <email@hidden>
  • Date: Thu, 6 Nov 2003 15:26:33 -0800

On 6 Nov, 2003, at 12:05 AM, Sean Gilbertson wrote:

On Nov 5, 2003, at 12:11 AM, Shawn Erickson wrote:

Otherwise I would consider modifying your data source on the main
thread only (possibly in bursts, queuing in your background threads a
little). This will insure that your view isn't updating at the same
time that your data source is changing. Look at using NSObject's
performSelectorOnMainThread.

I was looking through the documentation for this method. The main
thread does all the UI work, right?? That would work -- it's dirty,
but it will work. I only hope I don't catch the main thread in between
calls. Is that possible? I would hope that Cocoa would be intelligent
enough to avoid that, but who knows?

No, you won't catch the main thread in the middle of a function call. The performSelectorOnMainThread methods put the selector on the run loop, so it gets handled like UI events or timers get handled.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
References: 
 >Re: NSTableDataSources and multi-threading (From: Sean Gilbertson <email@hidden>)

  • Prev by Date: Re: contentSizeForFrameSize and frameSizeForContentSize for NSTabView and NSWindow?
  • Next by Date: Re: Praise for the many AppKit enhancements
  • Previous by thread: Re: NSTableDataSources and multi-threading
  • Next by thread: Re: NSTableDataSources and multi-threading
  • Index(es):
    • Date
    • Thread