Fix activation of the autosave timer after modify+save+modify cycle
There were two problems:
- modifiedAfterAutosave should be reset false every time we mark the image as clean. Otherwise it may keep the old value
- modifiedAfterAutosave value should be used only for the autosave slot entry. For restarting the time we should ask the timer itself
BUG:393266