properly handle undo/redo - note that your ObjectModel MUST implement CopyTo() properly in order to make Undo/Redo work as expected!

This commit is contained in:
Michael Becker 2019-12-16 06:14:50 -05:00
parent ac5c730c85
commit 782345c5d2
No known key found for this signature in database
GPG Key ID: 389DFF5D73781A12

View File

@ -418,7 +418,7 @@ namespace UniversalEditor.UserInterface
}
// push the new edit
EDITINFO edit = new EDITINFO(null, null, mvarObjectModel);
EDITINFO edit = new EDITINFO(null, null, mvarObjectModel.Clone() as ObjectModel);
undo.Push(edit);
// clear out all the redos