• 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: performSelector in next run loop?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: performSelector in next run loop?


  • Subject: Re: performSelector in next run loop?
  • From: Pontus Ilbring <email@hidden>
  • Date: Sat, 28 Jan 2006 21:14:49 +0100

On 1/28/06, Joshua Scott Emmons <email@hidden> wrote:
> It was suggested yesterday that, to perform a selector in the next
> run loop, one should use -performSelector:withObject:afterDelay:
>
> Is the delay passed to this significant? Or will the selector always
> be called in the next loop regardless of this value?

The delay matters, and other events will be handled during the delay.

> If the delay IS significant, what value should I give it?

If you pass it a delay of 0 I'd expect it to send your message as soon
as possible.

> Or is there something else (performSelector:target:argument:order:modes:?) that
> would work better?

On the other hand, if you're working on the main thread anyway then
performSelectorOnMainThread:withObject:waitUntilDone: can enqueue a
message to be sent in the next iteration of the run loop.

And if you want really fine-grained control then you could use
NSRunLoop's performSelector:target:argument:order:modes:.
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >performSelector in next run loop? (From: Joshua Scott Emmons <email@hidden>)

  • Prev by Date: Re: Running COCOA application during startup
  • Next by Date: Re: newb question on documents, nibs & the menu bar
  • Previous by thread: performSelector in next run loop?
  • Next by thread: Finder integration or plug-in
  • Index(es):
    • Date
    • Thread