• 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: Using NSTextField value without changing focus?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Using NSTextField value without changing focus?


  • Subject: Re: Using NSTextField value without changing focus?
  • From: Keary Suska <email@hidden>
  • Date: Tue, 11 Sep 2012 09:26:51 -0600

On Sep 11, 2012, at 7:17 AM, Koen van der Drift wrote:

> And as a followup, I am using bindings to link the value of the
> textfield to my controller to do the calculations. I als tried
> checking "Continuously Updates Value" in IB, but that also didn't
> work, I still need to unfocus the textfield for the new value to be
> used.

"Continuously Updates Value" is what you want, usually. I bet that if you put NSLogs in the setters you will find that they are being set immediately. If this isn't working, it means that your calculation method is not working on the same model as the bindings, or at least not an up-to-date copy, which is generally a bad idea. The calculation method should retrieve the values directly from the model owner on demand, which will do what you need.

HTH,

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

  • Follow-Ups:
    • Re: Using NSTextField value without changing focus?
      • From: Koen van der Drift <email@hidden>
    • Re: Using NSTextField value without changing focus?
      • From: Koen van der Drift <email@hidden>
References: 
 >Using NSTextField value without changing focus? (From: Koen van der Drift <email@hidden>)
 >Re: Using NSTextField value without changing focus? (From: Markus Spoettl <email@hidden>)
 >Re: Using NSTextField value without changing focus? (From: Koen van der Drift <email@hidden>)
 >Re: Using NSTextField value without changing focus? (From: Koen van der Drift <email@hidden>)

  • Prev by Date: Re: Using NSTextField value without changing focus?
  • Next by Date: Re: KVO Question: How to programmatically determine if one object is observing another on a keyPath and context?
  • Previous by thread: Re: Using NSTextField value without changing focus?
  • Next by thread: Re: Using NSTextField value without changing focus?
  • Index(es):
    • Date
    • Thread