Re: Cleaning up weak references ( was Re: Odd Crash when adding table columns manually )
Re: Cleaning up weak references ( was Re: Odd Crash when adding table columns manually )
- Subject: Re: Cleaning up weak references ( was Re: Odd Crash when adding table columns manually )
- From: "Sean McBride" <email@hidden>
- Date: Thu, 20 Jan 2011 16:56:59 -0500
- Organization: Rogue Research Inc.
On Thu, 20 Jan 2011 13:27:35 -0800, Corbin Dunn said:
>> For a specific example, check out the AnimatedTableView sample code
>from Apple. The ATColorTableController class is a datasource for the
>table, but it's dealloc looks like:
>>
>> - (void)dealloc
>> {
>> [_colorList release];
>> [_colorNames release];
>> [_window release];
>> [super dealloc];
>> }
>>
>> Based on my current understanding, the table controller's dealloc
>(above) should be setting the table datasource and delegate to nil.
>Correct? If so, I will file a bug.
>
>I wrote that sample, and gave the WWDC talk based on it a few years ago.
>I also "own" NSTableView.
>
>Yes, please do file a bug. The sample should set the delegate/datasource
>to nil, as it is good practice to do so, and we can update the sample.
In the case of garbage collected-only mode, do I assume correctly that
such setting to nil is not needed?
--
____________________________________________________________
Sean McBride, B. Eng email@hidden
Rogue Research www.rogue-research.com
Mac Software Developer Montréal, Québec, Canada
_______________________________________________
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