• 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
Custom view with NSTreeController
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Custom view with NSTreeController


  • Subject: Custom view with NSTreeController
  • From: Bryan Hansen <email@hidden>
  • Date: Sat, 1 Jan 2011 01:05:37 -0800

I'm trying to create a custom view which is backed by an NSTreeController. I've seem many threads discussing this without any real specific resolution. I'm familiar with how to get an NSOutlineView to bind to an NSTreeController but getting a custom view to replace the outline view is a challenge.

I have a custom view with an array to store its content which I am trying to bind via:

    [hierarchyView bind:@"content" toObject:treeController withKeyPath:@"arrangedObjects" options:NULL];

this has the affect of setContent being called with an NSControllerTreeProxy object rather than an array of objects on my custom view. I've noticed a few people trying to deal with this but haven't really seen a good working example. Is this even the correct way to setup the bindings or do I need to connect my view content with the NSTreeController differently?

Also, I'm open to a non-bindinds solution or on the other hand if it isn't worth using an NSTreeController, is there any advice on writing my own or using a good existing solution already out there?

Thanks,
Bryan

_______________________________________________

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: Event to trigger writeSelectionToPasteboard
  • Next by Date: Re: Event to trigger writeSelectionToPasteboard
  • Previous by thread: Re: Event to trigger writeSelectionToPasteboard
  • Next by thread: Re: Memory management about async object
  • Index(es):
    • Date
    • Thread