Class MacroCommand
A macro command is a command that contains other commands.
Inherited Members
Namespace: Unity.AppUI.Undo
Assembly: Unity.AppUI.Undo.dll
Syntax
public class MacroCommand : UndoCommand
Constructors
MacroCommand(string)
Creates a new macro command.
Declaration
public MacroCommand(string name)
Parameters
| Type | Name | Description |
|---|---|---|
| string | name | The name of the macro command. |
Properties
this[int]
Get the command at the specified index.
Declaration
public UndoCommand this[int index] { get; }
Parameters
| Type | Name | Description |
|---|---|---|
| int | index | The index of the command. |
Property Value
| Type | Description |
|---|---|
| UndoCommand |
id
The unique identifier of the macro command type.
Declaration
public override string id { get; }
Property Value
| Type | Description |
|---|---|
| string |
Overrides
memorySize
The memory size of the macro command.
Declaration
public override ulong memorySize { get; }
Property Value
| Type | Description |
|---|---|
| ulong |
Overrides
Methods
Add(UndoCommand)
Adds a command to the macro command.
Declaration
public void Add(UndoCommand command)
Parameters
| Type | Name | Description |
|---|---|---|
| UndoCommand | command | The command to add. |
OnFlush()
This will call OnFlush() on all the commands contained in the macro command.
Declaration
public override void OnFlush()
Overrides
Redo()
Redoes the macro command.
Declaration
public override void Redo()
Overrides
Undo()
Undoes the macro command.
Declaration
public override void Undo()