Core
Autodesk.Viewing.HotkeyManager
new HotkeyManager()
Management of hotkeys for the viewer.
Access the members and methods via the singleton theHotkeyManager.
Methods
popHotkeys(id)
Removes hotkeys associated with an ID from the stack.
Parameters
id* string | The id associated with the hotkeys. |
* Required
Returns
Type | Description |
---|---|
boolean | True if the hotkeys were successfully popped. |
pushHotkeys(id,hotkeys,options)
Pushes new hotkeys onto the stack.
Parameters
Expand all
id* string | The id for this hotkey set. |
hotkeys* Array.<Hotkey> | The list of hotkeys. |
options object | An optional dictionary of options for this hotkey set. |
tryUntilSuccess boolean | When true, the onPress callback will be called until it returns true or the hotkey state changes. The onRelease callback will be called until it returns true or until the combination is reengaged. Stops propagation through the stack. Non-blocking. |
* Required
Returns
Type | Description |
---|---|
boolean | True if the hotkeys were successfully pushed. |