Undomanager and deallocate
Undomanager and deallocate
- Subject: Undomanager and deallocate
- From: "Mark's Studio" <email@hidden>
- Date: Tue, 30 Oct 2001 10:11:18 +0100
What is the correct way of doing this, if any?
[[self undoManager] registerUndoWithTarget:self
selector:@selector(undoMethod:) object:[myObject copy]];
[[self undoManager] registerUndoWithTarget:self
selector:@selector(undoMethod:) object:[[myObject copy] autorelease]];
will the undoManager deallocate myObject when it's finish with it.
i have only tried [myObject copy] and it works without any errors, so is
that ok?
Thanks
Peter Mark
Mark's Recording Studio A/S
Faelledvej 19 b DK2200 N
Copenhagen Denmark
Tel: +45 35366078 Fax: +45 35366038
www.marks-studio.dk
email@hidden