Re: Want NSTableView NSOutlineView to load lazy like iOS?
Re: Want NSTableView NSOutlineView to load lazy like iOS?
- Subject: Re: Want NSTableView NSOutlineView to load lazy like iOS?
- From: Ken Thomases <email@hidden>
- Date: Mon, 15 Sep 2014 14:47:56 -0500
On Sep 15, 2014, at 1:52 PM, Jerry Krinock <email@hidden> wrote:
> OS X app has an NSOutlineView with a data source. Clicking on a disclosure triangle to expand an item that has 13,000 children causes its data source to immediately receive -outlineView:child:ofItem: 13,000 times, on the main thread. The app presents a beachball until it’s over, which is unacceptable.
Check the places where you can control how the outline view sizes the columns. In particular, from the docs for -[NSOutlineViewDelegate outlineView:sizeToFitWidthOfColumn:]:
"By default, NSOutlineView iterates every row in the table, accesses a cell via preparedCellAtColumn:row:, and requests the cellSize to find the appropriate largest width to use.
For accurate results and performance, it is recommended that this method is implemented when using large tables. By default, large tables use a monte carlo simulation instead of iterating every row."
Regards,
Ken
_______________________________________________
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