• 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: NSTreeController: how do I select a model object?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSTreeController: how do I select a model object?


  • Subject: Re: NSTreeController: how do I select a model object?
  • From: Shane Stanley <email@hidden>
  • Date: Tue, 15 Oct 2013 09:30:19 +1100

On 15 Oct 2013, at 8:18 AM, Jens Alfke <email@hidden> wrote:

> With an NSOutlineView driven by an NSTreeController, I’m having trouble figuring out how to programmatically select an item: given one of my model objects, how do I tell the controller or view to select it?

I'm using datasources, but that shouldn't matter:

    [self.outlineView selectRowIndexes:[NSIndexSet indexSetWithIndex:[self.outlineView rowForItem:item]] byExtendingSelection:NO];


--
Shane Stanley <email@hidden>
'AppleScriptObjC Explored' <www.macosxautomation.com/applescript/apps/>


_______________________________________________

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: NSTreeController: how do I select a model object?
      • From: Shane Stanley <email@hidden>
References: 
 >NSTreeController: how do I select a model object? (From: Jens Alfke <email@hidden>)

  • Prev by Date: NSTreeController: how do I select a model object?
  • Next by Date: Re: This document’s file has been changed by another application since you opened or saved it.
  • Previous by thread: NSTreeController: how do I select a model object?
  • Next by thread: Re: NSTreeController: how do I select a model object?
  • Index(es):
    • Date
    • Thread