Re: Was: Re: NSStepper - useless?

2012-02-26 Thread John Joyce
> > >> I'm just saying the stepper itself should not have a value, it should send >> actions to a controller so it can manipulate a numeric value in a model >> object, or it should be able (using bindings) to increment/decrement a >> model's value. Using the UI as a model isn't what MVC is al

Re: Was: Re: NSStepper - useless?

2012-02-26 Thread Seth Willits
On Feb 26, 2012, at 4:44 PM, William Squires wrote: >>> Why didn't they just make the NSStepper a custom view that draws two >>> arrows, and has two sent actions that you can connect? Or even a variation >>> of NSMatrix with two button cells that look like arrows. That would avoid >>> the probl

Re: Was: Re: NSStepper - useless?

2012-02-26 Thread Graham Cox
On 27/02/2012, at 11:44 AM, William Squires wrote: > I'm just saying the stepper itself should not have a value, it should send > actions to a controller so it can manipulate a numeric value in a model > object, or it should be able (using bindings) to increment/decrement a > model's value. Us

Re: Was: Re: NSStepper - useless?

2012-02-26 Thread William Squires
On Feb 23, 2012, at 2:13 PM, Seth Willits wrote: > On Feb 23, 2012, at 6:16 AM, William Squires wrote: > >> From what I've read, the NSStepper has a bug (though practically, you'll >> never see it); if one were to click the up or down arrow on the control 2^32 >> times (assuming it's value is

Re: Was: Re: NSStepper - useless?

2012-02-24 Thread Gregory Weston
William Squires wrote: > Why didn't they just make the NSStepper a custom view that draws two arrows, > and has two sent actions that you can connect? Or even a variation of > NSMatrix with two button cells that look like arrows. That would avoid the > problem entirely, and be more intuitive to

Re: Was: Re: NSStepper - useless?

2012-02-23 Thread Keary Suska
On Feb 23, 2012, at 10:05 AM, Kyle Sluder wrote: > On Thu, Feb 23, 2012 at 6:16 AM, William Squires wrote: >> From what I've read, the NSStepper has a bug (though practically, you'll >> never see it); if one were to click the up or down arrow on the control 2^32 >> times (assuming it's value is

Re: Was: Re: NSStepper - useless?

2012-02-23 Thread Seth Willits
On Feb 23, 2012, at 6:16 AM, William Squires wrote: > From what I've read, the NSStepper has a bug (though practically, you'll > never see it); if one were to click the up or down arrow on the control 2^32 > times (assuming it's value is a 4-byte signed int,and is initialized to 0), > it would

Re: Was: Re: NSStepper - useless?

2012-02-23 Thread Kyle Sluder
On Thu, Feb 23, 2012 at 6:16 AM, William Squires wrote: > From what I've read, the NSStepper has a bug (though practically, you'll > never see it); if one were to click the up or down arrow on the control 2^32 > times (assuming it's value is a 4-byte signed int,and is initialized to 0), > it wo

Was: Re: NSStepper - useless?

2012-02-23 Thread William Squires
>From what I've read, the NSStepper has a bug (though practically, you'll never >see it); if one were to click the up or down arrow on the control 2^32 times >(assuming it's value is a 4-byte signed int,and is initialized to 0), it would >wrap around (or raise an exception for integer overflow).

Re: NSStepper - useless?

2012-02-23 Thread Martin Hewitson
On Feb 22, 2012, at 09:11 PM, Seth Willits wrote: > On Feb 19, 2012, at 4:11 PM, William Squires wrote: > >> Okay, 'nuther dumb question. How do I hook the different arrows in an >> NSStepper to actions in my view controller? Or how do I ask (id)sender which >> arrow was clicked? > > You don'

Re: NSStepper - useless?

2012-02-23 Thread John Joyce
On Feb 19, 2012, at 6:11 PM, William Squires wrote: > Okay, 'nuther dumb question. How do I hook the different arrows in an > NSStepper to actions in my view controller? Or how do I ask (id)sender which > arrow was clicked? > Remember that classes tend to inherit from superclasses. Not checkin

Re: NSStepper - useless?

2012-02-23 Thread Jens Alfke
On Feb 19, 2012, at 4:11 PM, William Squires wrote: > Okay, 'nuther dumb question. How do I hook the different arrows in an > NSStepper to actions in my view controller? Or how do I ask (id)sender which > arrow was clicked? NSStepper is intended to keep track of the value for you, so when the

Re: NSStepper - useless?

2012-02-23 Thread Keary Suska
On Feb 19, 2012, at 5:11 PM, William Squires wrote: > Okay, 'nuther dumb question. How do I hook the different arrows in an > NSStepper to actions in my view controller? Or how do I ask (id)sender which > arrow was clicked? You can't, at least not specifically, on both counts. All the stepper d

Re: NSStepper - useless?

2012-02-22 Thread Graham Cox
On 20/02/2012, at 11:11 AM, William Squires wrote: > Okay, 'nuther dumb question. How do I hook the different arrows in an > NSStepper to actions in my view controller? Or how do I ask (id)sender which > arrow was clicked? You can't, it works differently. Instead it has a "value" , just like

Re: NSStepper - useless?

2012-02-22 Thread Fritz Anderson
On 19 Feb 2012, at 6:11 PM, William Squires wrote: > Okay, 'nuther dumb question. How do I hook the different arrows in an > NSStepper to actions in my view controller? Or how do I ask (id)sender which > arrow was clicked? It's not useless, it just doesn't have the use you hope for. NSStepper

Re: NSStepper - useless?

2012-02-22 Thread Seth Willits
On Feb 19, 2012, at 4:11 PM, William Squires wrote: > Okay, 'nuther dumb question. How do I hook the different arrows in an > NSStepper to actions in my view controller? Or how do I ask (id)sender which > arrow was clicked? You don't. You ask for the stepper's value. -- Seth Willits ___

NSStepper - useless?

2012-02-22 Thread William Squires
Okay, 'nuther dumb question. How do I hook the different arrows in an NSStepper to actions in my view controller? Or how do I ask (id)sender which arrow was clicked? ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin req