コード例 #1
0
 public void UndoLastOperation()
 {
     if (!_undoStack.IsEmpty)
     {
         UndoableOperation <TClass> undoableOperation = _undoStack.Pop();
         Undone(this, new GenericEventArgs <UndoableOperation <TClass> >(undoableOperation));
         undoableOperation.Implementor.Undo(undoableOperation.Command);
     }
 }
コード例 #2
0
 public void AddOperation(UndoableOperation <TClass> operation)
 {
     Added(this, new GenericEventArgs <UndoableOperation <TClass> >(operation));
     _undoStack.Push(operation);
 }