On Fri, Dec 5, 2008 at 7:55 AM, rajesh <[EMAIL PROTECTED]> wrote: > Hi All, > > I am working with NSOutlineView and I would like 'it' to work in hand with > NSTreeController. > > There are few columns which contain Images+Text , Text alone or Images > alone. > > I have just basic idea of how bindings work and Implementing them ( binding > the columns with text and images ) > > But the idea of going with bindings for columns with combination of text and > images is new arena for me. > I need to implement a custom cell which accommodates the image, There after > I am blank ..... > > Before jumping into this , I would like to know , Is it not a big deal for > implementing the above case ? or is it a bad idea > I tried Google'ng around but not of great help..... > > I greatly appreciate for any pointers or even sample code :)
The way things work from your cell's perspective, it will just receive calls to -setObjectValue: for each row, with the passed-in object being the individual objects from whatever you have bound to that column. So all you need to do is figure out what kind of object you want your cell to take, and then provide that. For an image-and-text cell, you could for example use a dictionary with @"image" and @"text" keys. You'd then have to ensure that your containers are populated with appropriately constructed dictionaries, and then your bindings would work. There are of course other possibilities you could go with at all, the basic point is just that your object types have to match what your cell will accept for -setObjectValue:. Mike _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]