• 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
Receiving controlTextDidChange: from change in bound value?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Receiving controlTextDidChange: from change in bound value?


  • Subject: Receiving controlTextDidChange: from change in bound value?
  • From: Chad Bailey <email@hidden>
  • Date: Wed, 17 Dec 2008 14:40:41 -0600

Hello list,

I have an NSTextField that has its Value attribute bound to an NSString object. When I update the NSString object from another place in my code, the value of my NSTextField updates appropriately (that's Bindings for you).

However, I'm trying to call sizeToFit on that NSTextField after it updates its value. I tried using the controlTextDidChange: delegate method, but it doesn't seem to fire when the control value is updated from bindings—only when the control is manipulated directly. I also tried adding code directly in a custom setter method for the NSString, but the value of the NSTextField doesn't seem to update until after the setter method completes (which makes sense).

Is there a way to fire that delegate method when the value of a control is updated via bindings, or is there another way I should be approaching this? Thanks in advance for your help.

-Chad Bailey_______________________________________________

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: Performance of calculation on float point numbers in a array • NSNumber in NSArray, or classic C array?
  • Next by Date: Error with malloc and NSFileWrapper
  • Previous by thread: Re: Performance of calculation on float point numbers in a array • NSNumber in NSArray, or classic C array?
  • Next by thread: Error with malloc and NSFileWrapper
  • Index(es):
    • Date
    • Thread