• 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
binding a TableView with non-CF collection data?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

binding a TableView with non-CF collection data?


  • Subject: binding a TableView with non-CF collection data?
  • From: Alex Rosenberg <email@hidden>
  • Date: Sun, 28 Nov 2004 20:04:30 -0800

I have an NSTableView. My model objects are legacy C++. I want to use bindings.

NSArrayController seems to insist on directly manipulating an NSArray or ObjC objects. I currently let it manipulate an NSArray of proxy objects and handle all the real model object manipulations in the to-many accessors (countOfXXX, objectInXXXAtIndex:, insertObject:inXXX:atIndex:, etc.). This also necessitates subclassing NSArrayController and replacing -newObject to create a real C++ model object backing it.

I don't currently see a clean way to avoid having all those proxy objects. mmalc has an example (Combatants, IIRC) where the array is synthesized, but the objects in the array are not. I need to synthesize both the array and the objects.

Any suggestions?

+------------------------------------------------------------+
| Alexander M. Rosenberg           <mailto:email@hidden> |
| Nobody cares what I say. Remove the underscore to mail me. |

_______________________________________________
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


  • Follow-Ups:
    • Re: binding a TableView with non-CF collection data?
      • From: "M. Uli Kusterer" <email@hidden>
    • Re: binding a TableView with non-CF collection data?
      • From: mmalcolm crawford <email@hidden>
  • Prev by Date: Re: NSTextView stringValue?
  • Next by Date: Re: Checking for line ending types
  • Previous by thread: Re: NSTextView stringValue?
  • Next by thread: Re: binding a TableView with non-CF collection data?
  • Index(es):
    • Date
    • Thread