Core Data and Undo action names
Core Data and Undo action names
- Subject: Core Data and Undo action names
- From: Kevin <email@hidden>
- Date: Sat, 10 Mar 2007 09:57:42 -0600
It's my understanding that in order to have meaningful Undo action
names, one has to manually set the action name in set accessor
methods for entities as such:
- (void)setTitle:(NSString *)value
{
[self willChangeValueForKey: @"title"];
[self setPrimitiveValue:value forKey:@"title"];
[self didChangeValueForKey: @"title"];
// Set action name
[[[self managedObjectContext] undoManager] setActionName:@"Edit
Folder Title"];
}
After reading the documentation on Core Data and Localization, I
created a MyModel.strings file but it only appears to use the
localized names for error messages related to model validation.
MyModel.strings is not consulted for action Undo/Redo names. Is this
the expected behavior or am I missing something?
Kevin
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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