• 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: NSCollectionView questions
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSCollectionView questions


  • Subject: Re: NSCollectionView questions
  • From: David Carlisle <email@hidden>
  • Date: Tue, 12 Feb 2008 16:05:35 -0700

You can set the tag in Interface Builder for NSPopUpButton and NSTextField, but in one case I needed to get an NSBox subview so I could manually bind to its fillColor. You cannot set a tag for NSBox in Interface Builder, so I needed to create a subclass, then override the tag method to return the tag number I was looking for.

DC

On Feb 12, 2008, at 3:02 PM, Dave Hayden wrote:

On Feb 11, 2008, at 2:59 PM, David Carlisle wrote:

I needed to put a pop up menu inside a view of a NSCollectionViewItem, then customize the contents of the menu using the representedObject.

I subclassed NSCollectionViewItem and augmented setView to cause "self" to be the delegate of the NSPopUpButton menu, obtained with [view ViewWithTag:n].

Ah, that's funny--I've never noticed -[NSView viewWithTag:] before. Seems kind of hacky, but yeah, that would work. Thanks for the tip!


-Dave
Panic, Inc.

_______________________________________________

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

_______________________________________________

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


References: 
 >NSCollectionView questions (From: Dave Hayden <email@hidden>)
 >Re: NSCollectionView questions (From: David Carlisle <email@hidden>)
 >Re: NSCollectionView questions (From: Dave Hayden <email@hidden>)

  • Prev by Date: Re: Newb question: which feature am I looking for?
  • Next by Date: Re: Newb question: which feature am I looking for?
  • Previous by thread: Re: NSCollectionView questions
  • Next by thread: Re: NSCollectionView questions
  • Index(es):
    • Date
    • Thread