|
From: | Richard Frith-Macdonald |
Subject: | Re: Question about NSRunLoop -runUntilDate: |
Date: | Mon, 01 Aug 2005 08:53:23 +0100 |
On 2005-08-01 08:12:37 +0100 Chris Vetter <cbv@gmx.net> wrote:
Hi there, I need to create a runloop that's supposed to run for X minutes. Naturally, -runUntilDate: comes to mind. So far, so good. My question is whether there is an appropriate method to get some/any kind of 'notification' that the runloop has stopped. I do not really care whether it stops because all input sources have been removed or the limitDate has been reached. I just need to send (or rather receive) a 'note' that the runloop stopped. Maybe this has an obvious answer but if so I can't see it... :-(
The documentation for -runUntilDate: saysRuns the loop in NSDefaultRunLoopMode by repeated calls to -runMode:beforeDate: while there are still input sources. Exits when no more input sources remain, or date is reached, whichever occurs first.
So I guess you could send the notification when the method returns.
[Prev in Thread] | Current Thread | [Next in Thread] |