Public Member Functions

cyber::editor::commands::CommandProcessor Class Reference

#include <CommandProcessor.h>

List of all members.

Public Member Functions

 CommandProcessor (void)
 CommandProcessor (size_t cmd_limit)
 ~CommandProcessor (void)
size_t get_cmd_limit () const
unsigned get_last_number () const
bool execute (Command *cmd)
bool undo ()
bool redo ()
bool dismiss_all ()
bool reject_all ()

Detailed Description

The hub for all user actions in the editor.


Constructor & Destructor Documentation

cyber::editor::commands::CommandProcessor::CommandProcessor ( void   ) 

Default constructor.

cyber::editor::commands::CommandProcessor::CommandProcessor ( size_t  cmd_limit  ) 

Explicit constructor.

cyber::editor::commands::CommandProcessor::~CommandProcessor ( void   ) 

Destructor.


Member Function Documentation

bool cyber::editor::commands::CommandProcessor::dismiss_all (  ) 

Dismisses all commands.

bool cyber::editor::commands::CommandProcessor::execute ( Command cmd  ) 

Executes the given command and pushes it on the undo stack.

size_t cyber::editor::commands::CommandProcessor::get_cmd_limit (  )  const [inline]

Returns the maximum number of undo/redo commands.

unsigned cyber::editor::commands::CommandProcessor::get_last_number (  )  const [inline]

Returns the number of the last executed command.

bool cyber::editor::commands::CommandProcessor::redo (  ) 

Redoes the last undone action on top of the redo stack.

bool cyber::editor::commands::CommandProcessor::reject_all (  ) 

Rejects all commands.

bool cyber::editor::commands::CommandProcessor::undo (  ) 

Undoes the last action on top of the undo stack.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines