• 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: Astoundingly dumb bindings question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Astoundingly dumb bindings question


  • Subject: Re: Astoundingly dumb bindings question
  • From: Keary Suska <email@hidden>
  • Date: Sun, 01 Jul 2007 12:38:07 -0600
  • Thread-topic: Astoundingly dumb bindings question

on 6/30/07 5:58 PM, email@hidden purportedly said:

> OK, I have looked at the docs, the archives, google, etc.  I seem to
> be having no luck doing something that should be crazy easy.  I want
> to have an NSPopUpButton, which is bound to an array of NSNumbers.  I
> have an action, which wants to grab the number from the selection of
> the popup, and do something with it, displaying the results of the
> calculation in a textfield.
>
> I could do this programmatically, but I was thinking some of this
> might be easier and quicker with bindings.

Not necessarily. And in your case specifically, not likely. Anyway, it's
really a matter of understanding what bindings are about. Bindings are
solely a means to synchronize data between (primarily) view objects and
model objects. Nothing more.

So, you will see you are missing up to two elements: the model object that
contains the number to be calculated (which the popup binds to via
selectedObject), and possibly the object that contains the calculated value.

Best,

Keary Suska
Esoteritech, Inc.
"Demystifying technology for your home or business"


_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Prev by Date: Re: How to make a view subclass like dashcodes "Widget Attribute" pannel
  • Next by Date: Re: KVO persists too long
  • Previous by thread: Re: How to make a view subclass like dashcodes "Widget Attribute" pannel
  • Next by thread: Re: KVO persists too long
  • Index(es):
    • Date
    • Thread