NSCollectionView and its Items
NSCollectionView and its Items
- Subject: NSCollectionView and its Items
- From: Joachim Deelen <email@hidden>
- Date: Tue, 2 Feb 2010 23:40:30 +0100
Hi,
is it possible, in Mac OS X 10.5, to get a list of the NSCollectionViewItems directly from the NSCollectionView. The "content" Message returns a list of the Represented-Objects, not the Items.
Currently I'm overwriting the "newItemForRepresentedObject". Within that method I'm putting the created items in an internal Array for later use. While debugging my App, under 10.6, I saw that NSCollectionView has a "_content" attribute which holds all the NSCollectionViewItems. But calling "content" on the CollectionView returns the Represented-Objects not the ViewItems.
I know in 10.6 there is a new method "itemAtIndex" which returns the ViewItem but since my App has to be 10.5 compatible I can not use it.
I can live with the workaround of overwriting "newItemForRepresentedObject" but to me it seems unnecessary because the CollectionView already has all the information.
Any Ideas?
-
Joachim
_______________________________________________
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