Public Types | |
enum | { CP_E_CH_UseCommandStatus = 1, CP_E_CH_AlwaysEnable = 2, CP_E_CH_AlwaysDisable = 4, CP_E_CH_DisableIfLowMemory = 8, CP_E_CH_DisableIfModalDialog = 0x10, CP_E_CH_EnableIfDocWindowTopmost = 0x20 } |
Public Member Functions | |
Constructor / Destructor | |
CP_Command () | |
Constructor. | |
CP_Command (const CP_Command &inCommand) | |
~CP_Command () | |
Destructor. | |
Getters | |
CP_CommandNo | GetCommand () |
SInt32 | GetCommandFlags () |
CP_CommandHandlerSignal * | GetCommandHandlerSignal () |
CP_CommandStatusSignal * | GetCommandStatusHandlerSignal () |
Operators | |
CP_Command & | operator= (const CP_Command &inCommand) |
Setters | |
void | SetCommand (CP_CommandNo inCommand) |
void | SetCommandFlags (SInt32 inFlags) |
void | SetCommandHandlerSignal (CP_CommandHandlerSignal *inSignal) |
void | SetCommandStatusSignal (CP_CommandStatusSignal *inStatusSignal) |
Private Attributes | |
CP_CommandNo | fCommand |
SInt32 | fCommandFlags |
CP_CommandHandlerSignal * | fCommandHandler |
CP_CommandStatusSignal * | fCommandStatus |
|
Flags used to set and get the status of commands.
|
|
Constructor. Sets all of the fields of this object to their default values. The default valaues for this object are 0, or NULL.
|
|
Copy constructor. Sets the fields of this object to those of the passed in CP_Command.
|
|
Destructor.
|
|
Returns the CP_CommandNo associated with this command.
|
|
Returns any flags associated with this command.
|
|
Returns the command handler signal associated with this command. This is the signal that will be called when the user selects this command from a menu, or otherwise causes the command number to be sent. The command and signal need to be registered with the CP_CommandHanlingManager first.
|
|
Returns the command status signal associated with this command. This is the signal that will be called whenn the status for this command needs to be updated, such as a menu opening. The command and signal need to be registered with the CP_CommandHanlingManager first. You can use this inplace of the CP_E_CH enumeration above to determine the status of enabled commands, if you need finer control than having a command always enabled or disabled, such as when the state of the command is determined by runtime conditions.
|
|
Assignment operator. Assigns data from the passed in CP_Command.
|
|
Sets the CP_CommandNo associated with this command.
|
|
Flags associated with this command and used to determine the status of the command. The flags should be one of the following:
|
|
Sets the signal associated with this command when it is selected, or sent by a control.
|
|
Sets the signal associated with this command needs to be enabled. This is used when you need finer control than that provided by the SetCommandFlags, such as when the state of a command is dependent upon some runtime conditionn.
|
|
|
|
CP_CommandNo assigned for this command. |
|
Flags used to find information out about the status of the command. |
|
Signal called to handle the command. |