1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 13:28:11 +00:00

LibGUI: Clear undo stack when opening a new document

This commit is contained in:
Carlos César Neves Enumo 2021-05-05 12:21:45 -03:00 committed by Andreas Kling
parent 88803b2e34
commit 67537bfc80
3 changed files with 9 additions and 0 deletions

View file

@ -80,4 +80,10 @@ void UndoStack::finalize_current_combo()
m_stack.prepend(move(undo_commands_container));
}
void UndoStack::clear()
{
m_stack.clear();
m_stack_index = 0;
}
}