public void DoAction(LegacyEditorAction act) { //Once we do a new thing, our redo list blows the hell up redoList.Clear(); //Then actually do the thing act.execute(); //This is a special tool that will help us later undoList.Push(act); }
public void Redo() { //If we have nothing to redo then we just quietly don't do anything if (redoList.Count > 0) { LegacyEditorAction act = redoList.Pop(); act.execute(); undoList.Push(act); FireModelChange(); } }