Re: Outline data sources
Re: Outline data sources
- Subject: Re: Outline data sources
- From: Andy Lee <email@hidden>
- Date: Sun, 14 Apr 2002 12:59:46 -0400
At 12:21 PM -0400 4/14/02, Mike O'Connor wrote:
I don't see many discussions of outlines, are
While I'm on the subject:
The trick to understanding outline views is that you don't map items
directly to row numbers, as you do with a table view. Instead, you
write datasource methods that answer the question: "Given an item,
what are the children of that item?" NSOutlineView handles all the
ugly details of figuring out which item is displayed in the Nth row,
depending on which items are expanded.
I found it helped to pick out the datasource methods that are
documented as "required," and add just those to my code, with empty
bodies at first. Seeing them all in one place helped me understand
how they work together. Then I could fill them in one by one as I
figured out what they meant.
--Andy
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.