- (void)dealloc
{
- //Remove ourselves as the delegate and data source to be safe
- [super setDataSource:nil];
- [super setDelegate:nil];
-
//Unregister the delegate from receiving notifications
[[NSNotificationCenter defaultCenter] removeObserver:_secondaryDelegate name:nil object:self];
- (void)finalize
{
- //Remove ourselves as the delegate and data source to be safe
- [super setDataSource:nil];
- [super setDelegate:nil];
-
//Unregister the delegate from receiving notifications
[[NSNotificationCenter defaultCenter] removeObserver:_secondaryDelegate name:nil object:self];
{
_secondaryDataSource = aDataSource;
- [self reloadData];
+ if ([self respondsToSelector:@selector(reloadData)])
+ [self reloadData];
}
- (void)setIconSize:(NSSize)newIconSize
- (void)reloadData
{
- [super reloadData];
+ if ([super respondsToSelector:@selector(reloadData)])
+ [super reloadData];
//Expand items that are displayed as always expanded
if([_secondaryDataSource conformsToProtocol:@protocol(PXSourceListDataSource)] &&