a) Project stayed in modified state even after undoing all changes.
b) Saving the project deleted the undo stack.
This commit is contained in:
Andre Rummler
2026-09-18 18:28:48 +02:00
parent 0258d1a74f
commit 059d179d9b
4 changed files with 28 additions and 4 deletions
+4 -1
View File
@@ -726,7 +726,10 @@ QETResult ProjectView::doSave()
// write to file
QETResult result = m_project -> write();
updateWindowTitle();
project()->undoStack()->clear();
// This marks the stack's current index as the new "saved" point (so isClean()/cleanChanged() correctly
// resume tracking unsaved changes from here) without discarding the undo history. Edits made before this save
// stay undoable for the rest of the session.
project()->undoStack()->setClean();
return(result);
}