• 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: NSArrayController in entity mode and permutations (CoreData question)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSArrayController in entity mode and permutations (CoreData question)


  • Subject: Re: NSArrayController in entity mode and permutations (CoreData question)
  • From: vincent habchi <email@hidden>
  • Date: Tue, 13 Apr 2010 21:51:06 +0200

Le 12 avr. 2010 à 23:17, Quincey Morris a écrit :

> I think I'm confused now about what scenario we are talking about. Are you saying that the object you insert with [NSArrayController insertObject...] is *not* a NSManagedObject, but is a proxy object that is linked to the NSManagedObject? Or are you referring to the NSArrayController itself as a proxy object?

Forget that story of proxies that was a botch. I reverted to the first scheme, followed your idea to implement a NSNumber attribute and a sort predicate. Well, it took me a whole day to figure out a clean algorithm to handle the renumbering caused by the drag-and-drop operation, but it works now, and is not plagued by any side effect anymore.

If you want to know a bit more, the managed object represents a "geographical data layer" (e.g.: roads, buildings, rivers, etc.). The user selects which gets drawn first, then which gets drawn over the first, etc. up to the highest layer, that lies atop all the others. This "ordered stack" is displayed on screen through a NSCollectionView whose contents observe the NSArrayController arrangedObjects. The user can drag and drop the NSView in the NSCollectionView to modify the drawing order.

Thanks a lot for your precious help, you and Kyle.

Vincent_______________________________________________

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: 
 >NSArrayController in entity mode and permutations (CoreData question) (From: vincent habchi <email@hidden>)
 >Re: NSArrayController in entity mode and permutations (CoreData question) (From: Quincey Morris <email@hidden>)
 >Re: NSArrayController in entity mode and permutations (CoreData question) (From: Quincey Morris <email@hidden>)
 >Re: NSArrayController in entity mode and permutations (CoreData question) (From: vincent habchi <email@hidden>)
 >Re: NSArrayController in entity mode and permutations (CoreData question) (From: Quincey Morris <email@hidden>)

  • Prev by Date: Re: "Operation could not be completed. No such file or directory"
  • Next by Date: How does an NSTextField know that it's value has changed?
  • Previous by thread: Re: NSArrayController in entity mode and permutations (CoreData question)
  • Next by thread: Disappearing prefs
  • Index(es):
    • Date
    • Thread