On Jun 1, 2015, at 2:39 PM, Quincey Morris 
<[email protected]<mailto:[email protected]>>
 wrote:

On Jun 1, 2015, at 13:59 , Lee Ann Rucker 
<[email protected]<mailto:[email protected]>> wrote:

Because I couldn’t possibly be the only person using that …

What does that dangling “because” refer to? I can’t make it out.

My previous comment where I said I was using it to show the “path” to the 
current NSTreeController selection. I create my own NSPathComponentCells by 
finding each treeNode between the root and the selection. The cell's 
representedObject is the NSTreeNode for that part of the “path” & the 
title/image comes from the [treeNode representedObject], and the IBAction uses 
[clickedPathComponentCell representedObject] to find it.

   NSIndexPath *iterationPath = [[self.treeController selectionIndexPaths] 
firstObject];
   NSMutableArray *pathComponentArray = [NSMutableArray array];
   NSTreeNode *topNode = [self.treeController arrangedObjects];

   while ([iterationPath length] > 0) {
      NSTreeNode *treeNode = [topNode descendantNodeAtIndexPath:iterationPath];
      [pathComponentArray insertObject:[self componentCellFromNode:treeNode]
                               atIndex:0];
      iterationPath = [iterationPath indexPathByRemovingLastIndex];
   }
   [pathControl setPathComponentCells:pathComponentArray];

_______________________________________________

Cocoa-dev mailing list ([email protected])

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to