• 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: NSStepper - How can I tell which arrow has been clicked?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSStepper - How can I tell which arrow has been clicked?


  • Subject: Re: NSStepper - How can I tell which arrow has been clicked?
  • From: Lance Bland <email@hidden>
  • Date: Fri, 19 Apr 2002 18:14:19 -0400

Julian-

On Friday, April 19, 2002, at 05:46 PM, Julian Barkway wrote:

Any ideas? The documentation on this topic is pretty much worthless.

Wow! I have never used NSStepper, but I see what you mean.

You may want to do this:

get the initial value from the stepper by calling [stepper intValue] and store that.

Then in the action method call [stepper intValue] again. If the return value is greater than the initial value then it increased (up arrow clicked) , otherwise it decreased (down arrow clicked). Then store that int value for the next time the action method is called so you can do the same thing.

You may also want to use a NSMatrix and two cells with left and right or up and down arrows. That way you can get which arrow was clicked.

-lance

------------------------------------
Lance Bland
mailto:email@hidden
web charts at http://www.vvi.com/products/chart
_______________________________________________
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.

References: 
 >NSStepper - How can I tell which arrow has been clicked? (From: Julian Barkway <email@hidden>)

  • Prev by Date: Re: Setting environment variables for Project Builder
  • Next by Date: Re: NSStepper - How can I tell which arrow has been clicked?
  • Previous by thread: NSStepper - How can I tell which arrow has been clicked?
  • Next by thread: Re: NSStepper - How can I tell which arrow has been clicked?
  • Index(es):
    • Date
    • Thread