• 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: Newbie Q - responding appropriately to buttons
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

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.

  • Follow-Ups:
    • Re: Newbie Q - responding appropriately to buttons
      • From: Henry McGilton <email@hidden>
References: 
 >Newbie Q - responding appropriately to buttons (From: Robert Palmer Jr <email@hidden>)

  • Prev by Date: Re: Newbie Q - responding appropriately to buttons
  • Next by Date: Re: NSWindowDepth Encoding
  • Previous by thread: Re: Newbie Q - responding appropriately to buttons
  • Next by thread: Re: Newbie Q - responding appropriately to buttons
  • Index(es):
    • Date
    • Thread