![]() |
Rogue Wave Views |
Rogue Wave Views Documentation Home |
Container accelerator class. More...
#include <ilviews/contain/contain.h>
Public Member Functions | |
| IlvContainerAccelerator (IlvContainerAction action=0, IlvEventType type=(IlvEventType) 0, IlUShort data=0, IlUShort modifiers=0, IlAny userArg=0, IlUShort optModifiers=0) | |
| Constructor. More... | |
| IlvContainerAction | action () const |
| Returns the accelerator action. More... | |
| virtual void | activate (IlvContainer *cont, IlvEvent &event) const |
| Calls the accelerator action. More... | |
| void | setAction (IlvContainerAction action, IlAny userArg) |
| Sets the accelerator action. More... | |
Public Member Functions inherited from IlvAccelerator | |
| IlUShort | data () const |
| Gets the event data. More... | |
| IlBoolean | match (IlvEventType type, IlUShort data, IlUShort modifiers) const |
| Tests if two accelerator descriptions are equivalent. More... | |
| IlUShort | modifiers () const |
| Gets the modifiers. More... | |
| IlUShort | modMask () const |
| Gets the modifiers to ignore. More... | |
| void | setModMask (IlUShort modifiersToIgnore) |
| Sets the modifiers to ignore. More... | |
| IlBoolean | trigger (IlvEventType type, IlUShort data, IlUShort modifiers) const |
| Tests if an event triggers an accelerator. More... | |
| IlvEventType | type () const |
| Gets the event type. More... | |
| IlAny | userArg () const |
| Gets the user argument. More... | |
Container accelerator class.
Library: views
This subclass of IlvAccelerator is defined for use accelerators in an IlvContainer. It defines a function type for the accelerator action and provides storage for this action. Generally, applications do not need to use this class. Instead, they use the versions of IlvContainer::addAccelerator(), IlvContainer::getAccelerator() and IlvContainer::removeAccelerator() where they provide the accelerator description (event, modifier, action).
IlvContainer. | IlvContainerAccelerator::IlvContainerAccelerator | ( | IlvContainerAction | action = 0, |
| IlvEventType | type = (IlvEventType)0, |
||
| IlUShort | data = 0, |
||
| IlUShort | modifiers = 0, |
||
| IlAny | userArg = 0, |
||
| IlUShort | optModifiers = 0 |
||
| ) |
Constructor.
Calls the constructor of the superclass with the event description and sets the accelerator action with its user argument.
| action | The accelerator action. |
| type | Specifies the type of event that triggers the action. |
| data | Specifies the event data. |
| modifiers | The event modifiers. |
| userArg | The user argument for the accelerator action. |
| optModifiers | The optional event modifiers. |
| IlvContainerAction IlvContainerAccelerator::action | ( | ) | const |
Returns the accelerator action.
|
virtual |
Calls the accelerator action.
Virtual member function called when the container has received an event fulfilling the conditions required to trigger the accelerator. (See method IlvAccelerator::trigger().) The default implementation is to call the action (if any) associated with the accelerator:
| cont | The container. |
| event | The event. |
| void IlvContainerAccelerator::setAction | ( | IlvContainerAction | action, |
| IlAny | userArg | ||
| ) |
Sets the accelerator action.
Sets both the accelerator action and the user argument.
| action | The accelerator action. |
| userArg | The user argument for the accelerator action. |
© Copyright 2015, Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave is a registered trademark of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.