KDE3Support
K3MacroCommand Class Reference
A Macro Command is a command that holds several sub-commands. More...
#include <k3command.h>

Public Member Functions | |
void | addCommand (K3Command *command) |
virtual void | execute () |
K3MacroCommand (const QString &name) | |
virtual void | unexecute () |
virtual | ~K3MacroCommand () |
Protected Member Functions | |
const QList< K3Command * > | commands () const |
virtual void | virtual_hook (int id, void *data) |
Detailed Description
A Macro Command is a command that holds several sub-commands.It will appear as one to the user and in the command history, but it can use the implementation of multiple commands internally.
Definition at line 126 of file k3command.h.
Constructor & Destructor Documentation
K3MacroCommand::K3MacroCommand | ( | const QString & | name | ) |
Creates a macro command.
You will then need to call addCommand for each subcommand to be added to this macro command.
- Parameters:
-
name the name of this command, translated, since it will appear in the menus.
Definition at line 76 of file k3command.cpp.
K3MacroCommand::~K3MacroCommand | ( | ) | [virtual] |
Definition at line 82 of file k3command.cpp.
Member Function Documentation
void K3MacroCommand::addCommand | ( | K3Command * | command | ) |
Appends a command to this macro command.
The ownership is transfered to the macro command.
Definition at line 87 of file k3command.cpp.
Definition at line 109 of file k3command.cpp.
void K3MacroCommand::execute | ( | ) | [virtual] |
Executes this command, i.e.
execute all the sub-commands in the order in which they were added.
Implements K3Command.
Definition at line 92 of file k3command.cpp.
void K3MacroCommand::unexecute | ( | ) | [virtual] |
Undoes the execution of this command, i.e.
unexecute all the sub-commands in the _reverse_ order to the one in which they were added.
Implements K3Command.
Definition at line 100 of file k3command.cpp.
void K3MacroCommand::virtual_hook | ( | int | id, | |
void * | data | |||
) | [protected, virtual] |
The documentation for this class was generated from the following files: