You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is probably me not understanding the changes in 1.2, but when I undo an action, then redo it, and then try to take a new action, the undo manager crashes with an Unexpected change received.
Am I supposed to send redone changes to the change stream as well?
The text was updated successfully, but these errors were encountered:
Yes. Doesn't that make the code easier, not having to care whether to push a change to the UndoManager or not? Just uniformly push all the changes.
Btw, that was the assumption in pre-1.2 too, that UndoManager would receive all the changes. In pre-1.2, it just ignored any changes received while doing undo/redo. In 1.2, it checks whether the incoming change is exactly the same (as per equals) as the one being re-done.
That does make it simpler. I was manually handling this before, but this is nice since I don't have to think about it anymore.
I do, however, suggest noting it somewhere, because I suspect when people think about undo, one of the first questions that come up is how do I not cause an infinite loop of undone changes causing new undoable changes (at least, it was what I was thinking about).
I'll close the issue too, since the question's been answered.
This is probably me not understanding the changes in 1.2, but when I undo an action, then redo it, and then try to take a new action, the undo manager crashes with an
Unexpected change received
.Am I supposed to send redone changes to the change stream as well?
The text was updated successfully, but these errors were encountered: