Menu

#12 action-a, action-b, undo, undo, redo, redo fails

open
nobody
ReJava GUI (30)
5
2006-10-08
2006-10-08
Sami Koivu
No

Some of the actions, while supporting undo and redo do
not support the contract of the undoable actions.

For example performing the two following actins:
*Create method
*Modify method (name for instance)

Undo both actions.

Redo create method: OK
Redo modify method: NOT OK - the modify method action
has a reference to a Method object created inicially,
but the redo create method creates a new Method action
which is the one that should be modified.

The simplest solution seems to be adjusting the
existing actions so that the bulk of creating new
objects would be done in the initializer and not in the
perform method. That way it will "always create the
same object".

Discussion


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.