Interface IUndo

The IUndo interface provides an interface for a simple undo redo system for recording changes on a single object. Only one undo action can be active at a time.

interface IUndo {
    endUndo(): any;
    startUndo(description: string, isBatchingChildCommands?: boolean): any;
}

Implemented by

Methods

  • Ends an undo operation. This must record the new state.

    Returns any

  • Starts an undo operation.

    Parameters

    • description: string

      The description of the undo operation.

    • OptionalisBatchingChildCommands: boolean

      If true, further pairs calls to startUndo and endUndo will not produce undo commands until the matching endUndo command for this command is called.

    Returns any