• 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
NSManagedObjects bound to an NSPopUpBotton in a toobar
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSManagedObjects bound to an NSPopUpBotton in a toobar


  • Subject: NSManagedObjects bound to an NSPopUpBotton in a toobar
  • From: Richard Wolf <email@hidden>
  • Date: Mon, 30 Apr 2007 17:50:37 -0500

I learnt something today. Maybe it will be useful to you guys ... didn't see anything in any of the usual Cocoa places describing it ... so I hope documenting here may save someone a bit of hassle at some point. I'll probably drop a line in Apple's radar after I play with it a bit more ... so anywho ...

If you have an NSToolbar ... and if you put an NSPopUpButton within it ... and if you bind that NSPopUpButton to a set of NSManagedObjects by way of NSArrayController, then you have to implement initWithCoder and encodeWithCoder in your NSManagedObject subclass. The NSCoding methods can be stubs that do nothing but return and return nil respectively ... but if you don't adopt the NSCoding protocol (even though it's useless in CoreData), then whenever an end user tries to customize your toolbar, he/she will experience all sorts of fun problems. :)

Back to cocoa-dev lurking.  :)
_______________________________________________

Cocoa-dev mailing list (email@hidden)

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: Byte swapping using NSInputStream
  • Next by Date: Re: Hide baseline separator in toolbar
  • Previous by thread: Re: Byte swapping using NSInputStream
  • Next by thread: NSImageView setAnimates:YES... PLEASE?
  • Index(es):
    • Date
    • Thread