Eclipse Community Forums - RDF feed
https://www.eclipse.org/forums/
Eclipse Community ForumsPatterns - DeleteFeature hasDone problem
https://www.eclipse.org/forums/index.php/mv/msg/237334/719913/#msg_719913
I've got a problem with the deletion of diagram elements using patterns. I'm using Graphiti 0.9.0.v20110818-1338.
The pattern implementations use the class DeleteFeatureForPattern that extends DefaultDeleteFeature and therefore contain its own property doneChanges. Following the attribute chain delegate --> pattern --> wrappedDeleteFeature, there's a different instance of DefaultDeleteFeature that handles the actual object deletion and sets its own attribute doneChanges to true. The command stack performs a check to see whether any changes were made, and as far as I can see, it only checks the "outer" DeleteFeatureForPattern instance. The doneChanges attribute of this class is never set to true, so the entire undo stack is reverted. I'll attach a screenshot to illustrate the problem.
I'm not entirely sure, but I think I've found a bug - could anyone confirm this?
Thanks
Volker]]>Volker Wegert2011-08-29T12:45:00-00:00Re: Patterns - DeleteFeature hasDone problem
https://www.eclipse.org/forums/index.php/mv/msg/237334/719937/#msg_719937
Thanks,
Michael
I've got a problem with the deletion of diagram elements using patterns. I'm
using Graphiti 0.9.0.v20110818-1338.
The pattern implementations use the class DeleteFeatureForPattern that
extends DefaultDeleteFeature and therefore contain its own property
doneChanges. Following the attribute chain delegate --> pattern -->
wrappedDeleteFeature, there's a different instance of DefaultDeleteFeature
that handles the actual object deletion and sets its own attribute
doneChanges to true. The command stack performs a check to see whether any
changes were made, and as far as I can see, it only checks the "outer"
DeleteFeatureForPattern instance. The doneChanges attribute of this class is
never set to true, so the entire undo stack is reverted. I'll attach a
screenshot to illustrate the problem.
I'm not entirely sure, but I think I've found a bug - could anyone confirm
this?