• 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: Why does NSCollectionView want to encode items in PopUp Menu?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Why does NSCollectionView want to encode items in PopUp Menu?


  • Subject: Re: Why does NSCollectionView want to encode items in PopUp Menu?
  • From: Graham Cox <email@hidden>
  • Date: Thu, 17 Jun 2010 10:03:50 +1000

On 17/06/2010, at 9:20 AM, Jerry Krinock wrote:

> Why might the collection view feel it needs to encode the items in this popup menu?


Isn't the view template copied by archiving/dearchiving, since NSView doesn't support NSCopying?

A similar problem I've run into is that when you set -representedObject on a menu item that has any possibility of being displayed in a toolbar, collection view or any other place that might be "copied", the object set must conform to NSCoding. On 10.5, toolbar items were copied in this way when displayed in the customise sheet, though in 10.6 that was changed to just render an image of the control instead (since the controls don't need to actually function there). But for views that must be functional, that wouldn't work so representedObjects must support NSCoding. It might be worth filing a bug against the docs for that method to point out this.

--Graham


_______________________________________________

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: Why does NSCollectionView want to encode items in PopUp Menu?
      • From: Jerry Krinock <email@hidden>
References: 
 >Why does NSCollectionView want to encode items in PopUp Menu? (From: Jerry Krinock <email@hidden>)

  • Prev by Date: Why does NSCollectionView want to encode items in PopUp Menu?
  • Next by Date: (no subject)
  • Previous by thread: Why does NSCollectionView want to encode items in PopUp Menu?
  • Next by thread: Re: Why does NSCollectionView want to encode items in PopUp Menu?
  • Index(es):
    • Date
    • Thread