• 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: silly event question 'cuz i'm a n00b
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: silly event question 'cuz i'm a n00b


  • Subject: Re: silly event question 'cuz i'm a n00b
  • From: Jamie Hardt <email@hidden>
  • Date: Wed, 8 Oct 2008 20:10:42 -0700

It sounds like you want an NSOperationQueue, which would map to your problem on a high level.

http://developer.apple.com/documentation/Cocoa/Reference/NSOperationQueue_class/Reference/Reference.html

I don't know Win32, but PostMessage() sounds a lot like NSNotificationCenter's postNotificationName:object:. You could do this to roll your own process list-thing using this and posting messages to your main NSRunLoop asynchronously, but you'd probably end up with something that looks a lot like NSOperationQueue.

On Oct 8, 2008, at 7:46 PM, John Zorko wrote:


Hello, all ...

If a certain flag is set, my app needs to advance to the next item in a list to process it when the previous item is done. However, I want the user to still be able to stop it, so I don't want to hang the UI. In effect, if this flag is set, I want the app to act as if the user had manually selected the next item to process.

In Win32, one way I could do this is by using PostMessage() -- when the current item is finished processing, it would post a message to the relevant threads' message queue and it would get processed, just as if the message was put there as a result of a GUI action. How do I do this in Cocoa, or is there a better way?

Jamie Hardt The Sound Department http://www.soundepartment.com/ http://www.imdb.com/name/nm0362504/

_______________________________________________

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: 
 >silly event question 'cuz i'm a n00b (From: John Zorko <email@hidden>)

  • Prev by Date: Re: NSTextView/NSAttributedString supported file types
  • Next by Date: Re: silly event question 'cuz i'm a n00b
  • Previous by thread: silly event question 'cuz i'm a n00b
  • Next by thread: Re: silly event question 'cuz i'm a n00b
  • Index(es):
    • Date
    • Thread