• 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
NSTextField when emptied sets bound ivar to nil?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSTextField when emptied sets bound ivar to nil?


  • Subject: NSTextField when emptied sets bound ivar to nil?
  • From: Fritz Anderson <email@hidden>
  • Date: Sat, 31 Jan 2009 13:54:57 -0600

This may be something I should have noticed years ago, but I'm surprised. I'm checking it with the list to see if it's normal or something to worry about. I wasn't able to Google anything on-point.

SDK is 10.4u, target 10.3, operating environment is 10.5.6.

I have an NSTextField bound through an NSController to a getter/setter property of my model class. The property must not be nil, and when the NSTextField first appears, it reflects the value of the property.

However, clearing the field (tab in, delete) passes nil into the setter. This surprises me; I expected @"".

The workaround is obvious, but (1) is this the expected, and documented behavior (and, as I said, something I should have known about years ago)? (2) Or is it something to worry about?

	— F

_______________________________________________

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: Newbie Object Sharing Question
  • Next by Date: Re: Newbie Object Sharing Question
  • Previous by thread: Re: Core Data relationship disappears
  • Next by thread: How many processors?
  • Index(es):
    • Date
    • Thread