|
BlankMat 0.1.0
Free open-source 3D texture creation application
|
Doubly linked node that stores the do and undo command of an action. More...

Public Member Functions | |
| bool | HasPrev () const |
| Returns whether this action has a previous node. | |
| bool | HasNext () const |
| Returns whether this action has a next node. | |
| bool | HasCommand () const |
| Returns whether this action has a valid command. | |
| bool | CanUndo () const |
| Returns whether this action can be undone. | |
| void | Execute () |
| Executes the command of the node. | |
| void | Undo () |
| Undoes the command of the node. | |
| bool | Combine (ICommand *&newCommand) |
| Attempts to combine the new command with the current command. | |
| std::string | GetName () const |
| Returns the name of the command. | |
| ActionNode (ActionNode *prev, ActionNode *next, ICommand *command) | |
| Creates a new action node for the given command. | |
Public Attributes | |
| ActionNode * | mPrevNode |
| The previous node of the action. | |
| ActionNode * | mNextNode |
| The next node of the action. | |
| ICommand * | mCommand |
| The command that the node executes. | |
Doubly linked node that stores the do and undo command of an action.
|
inline |
Creates a new action node for the given command.
| prev | Previously run node |
| next | Next node (should be null) |
| command | Command to run |
|
inline |
Returns whether this action can be undone.
|
inline |
Attempts to combine the new command with the current command.
| newCommand | New command to try combining |
|
inline |
Executes the command of the node.
|
inline |
Returns the name of the command.
|
inline |
Returns whether this action has a valid command.
|
inline |
Returns whether this action has a next node.
|
inline |
Returns whether this action has a previous node.
|
inline |
Undoes the command of the node.
| ICommand* ActionNode::mCommand |
The command that the node executes.
| ActionNode* ActionNode::mNextNode |
The next node of the action.
| ActionNode* ActionNode::mPrevNode |
The previous node of the action.