Infinite loop when going back from aspect

Issue #397 resolved
Cécile Camillieri created an issue

The app locks itself when going back from an aspect without saving after an undone action.

  • Open a RAM model
  • Make any change to the model.
  • Save
  • Undo
  • Press 'back' and say 'no' to saving

The app loops indefinitely in DisplaySceneHandler.switchToConcern(..):

while (EMFEditUtil.getCommandStack(scene.getAspect()).isSaveNeeded()) {
    EMFEditUtil.getCommandStack(scene.getAspect()).undo();
}

This happens because in this case, undoing will not allow us to go back to the previous saved state. In this situation operations should be redone. (I'm not sure redoing is needed though, we just need to check in the loop to be more precise)

Comments (4)

  1. Log in to comment