copyWithZone confusion
copyWithZone confusion
- Subject: copyWithZone confusion
- From: Coleman Nitroy <email@hidden>
- Date: Mon, 10 Jan 2005 20:24:17 -0500
My memory management theory is a little weak in some areas and recently
I ran into an error I cannot battle myself.
I am doing this
- (id)outlineView:(NSOutlineView *)ov
objectValueForTableColumn:(NSTableColumn *)tableColumn byItem (id)item
{
return item;
}
So that I can do this:
- (void) outlineView:(NSOutlineView *)outlineView
willDisplayCell:(id)cell forTableColumn:(NSTableColumn *)tableColumn
item:(id)item
{
// determine correct icon
if ( [[item nodeType] compare:@"Brush"] == NSOrderedSame ) {
[cell setImage:[NSImage imageNamed:@"Brush-icon"]];
} else {
[cell setImage:nil];
}
[cell setStringValue:[item nodeName]];
[cell setLeaf:YES];
}
And items are of a class I made called ATMap, for the purpose of this
problem it has two NSStrings in it, nodeName and nodeType. When I run
this code I get this error message:
*** -[ATMap copyWithZone:]: selector not recognized
How would I implement copyWithZone properly and what is really
happening and why does this happen? (Sorry that may be a bit vague)
Thanks.
---
Coleman Nitroy
email@hidden
nitroy.com/cole
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden