How to name undo and redo actions in a simple Core Data app?

I have a somewhat complex data model in my iPad application (an OpenGL drawing app), and I'm working on implementing undo/redo functionality. I like the fact that Core Data will undo data model changes for free, but I don't know if the built-in functionality will be sufficient for me. Tell the managed object context to undo.

Redraw everything on the page from the changed data model. This is horribly inefficient - in my app I need to be able to perform an action to undo based on the particular object that is being 'undone', and often this means refreshing only part of the canvas. So my question is this: can I register my own undo operations and use that in conjunction with the built-in undos?

When I come to undo this action, will the invocation be fired and the model changed appropriately? Or does this situation require that I abandon the built-in managed object context undo system and roll my own using just the NSUndoManager, including deleting and editing the data model myself? Edit: I suspect (if the idea above was to work) I would need to wrap it into an undo group, so that my registered undo operation would be grouped with the data model changes?

Another Edit: Also, can I guarantee the order in which undo actions will be carried out? In other words, if I call undo after the core data changes are saved and my undo action is registered, can I be sure that a deleted entity will be reinstated before my undo action is called?

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions