Re: Newbie Q - responding appropriately to buttons
Re: Newbie Q - responding appropriately to buttons
- Subject: Re: Newbie Q - responding appropriately to buttons
- From: j o a r <email@hidden>
- Date: Wed, 18 Jun 2003 22:42:55 +0200
On Wednesday, Jun 18, 2003, at 22:16 Europe/Stockholm, Robert Palmer Jr
wrote:
Is there an alternative method using notifications or messages? Is
there a way to have the button post a notification so that the search
doesn't happen immediately, but after the next run loop execution.
This way the button would flash. Of course, once the search actually
started, the application would still be held up for 5 seconds, but
again, for the moment, that's ok.
You would do something like this:
- (void) reallyPerformActionMethod
{
// Perform stuff here
}
- (void) someActionMethod:(id) sender
{
// Delay action here
[self performSelector: @selector(reallyPerformActionMethod)
withObject: nil afterDelay: 0.0];
}
This mehtod is "documented" in NSRunloop.h
j o a r
_______________________________________________
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.