2D Graphics > Managers > Manager Event Handling > Accelerators
 
Accelerators
An accelerator is a simple binding of an event description with an application function called the accelerator action. Accelerators provide a quick way of attaching a behavior to a manager, but the interaction is basic; it only involves one event (for instance, a key press or a mouse click).
An accelerator is not bound to a particular view or graphic object; it can be triggered in any view or any object of the manager. However, accelerators come last in the manager event dispatching mechanism. They can only be activated if event hooks, view interactors, and object interactors have not intercepted the event.
The accelerator action must be defined as an IlvManagerAcceleratorAction:
typedef void (* IlvManagerAcceleratorAction)(IlvManager*, IlvView*,
IlvEvent&, IlAny);
The following IlvManager member functions allow you to manipulate manager accelerators:
*IlvManager::addAccelerator
*IlvManager::getAccelerator
*IlvManager::removeAccelerator
*IlvManager::shortCut
The IlvManager::shortCut member function is called to dispatch an event to accelerators. If an accelerator event description matches the event to dispatch, the accelerator action is called.

Version 6.0
Copyright © 2015, Rogue Wave Software, Inc. All Rights Reserved.