• 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: Core Data and NSTreeController Editing Problem.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Core Data and NSTreeController Editing Problem.


  • Subject: Re: Core Data and NSTreeController Editing Problem.
  • From: Kevin Spraggs <email@hidden>
  • Date: Thu, 8 Sep 2005 16:30:23 +0100

On the basis of "Praise in public..." I'd like to say thank you Matt!

I have yet to really delve into your example code, but the add to the managed object context is
an excellent example (to this cocoa newbie) of lateral thinking that would have taken me an age to think of.


I expect that I will be asking further questions sooner rather than later ;-)

Cheers!

Kevin

On 6 Sep 2005, at 20:02, email@hidden wrote:

From: Matthew Holiday <email@hidden>
Subject: Re: Core Data and NSTreeController Editing Problem.
To: email@hidden
Message-ID: <email@hidden>
Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed


I have a modified version of the OutlineEdit example that includes
drag-n-drop (and so has been named DragAndDropOutlineEdit) to which
I've made a small change which does exactly what you're looking for
(see -[MyDocument createNoteWithParent:]). You can find the code at:
http://homepage.mac.com/matthol2/cocoa/page2/page2.html.

Working with Core Data, outline views, and tree controllers seems to
involve a few tricks to translate between indexes in the tree
controller and outline items (which can then be translated into table
rows). I avoid using reloadData or the tree controller add/insert
methods -- I add things into the managed object context, then find
them in the tree controller, and ask the outline to select them. The
magic happens in an extension to NSTreeController (-
outlineItemForObject:).




_______________________________________________ Do not post admin requests to the list. They will be ignored. Cocoa-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
  • Prev by Date: Re: NSValidationNumberTooSmallError with incomplete error message
  • Next by Date: Re: string help
  • Previous by thread: Re: Core Data and NSTreeController Editing Problem.
  • Next by thread: Newbie problem
  • Index(es):
    • Date
    • Thread