Namespace: utils

tabOverride.utils

Namespace for utility methods
Source:

Methods

(static) addListeners(elem)

Adds the Tab Override event listeners to the specified element. Hooks: addListeners - passed the element to which the listeners will be added.
Parameters:
Name Type Description
elem Element the element to which the listeners will be added
Source:

(static) createListeners(handlerList) → {tabOverride.utils~listenersObj}

Creates functions to add and remove event listeners in a cross-browser compatible way.
Parameters:
Name Type Description
handlerList Array.<tabOverride.utils~handlerObj> an array of handlerObj objects
Source:
Returns:
a listenersObj object used to add and remove the event listeners
Type
tabOverride.utils~listenersObj

(static) executeExtensions(hook, argsopt)

Executes all registered extension functions for the specified hook.
Parameters:
Name Type Attributes Description
hook string the name of the hook for which the extensions are registered
args Array <optional>
the arguments to pass to the extension
Source:

(static) isValidModifierKeyCombo(modifierKeys, e) → {boolean}

Determines whether the specified modifier keys match the modifier keys that were pressed.
Parameters:
Name Type Description
modifierKeys Array.<string> the modifier keys to check - ex: ['shiftKey']
e Event the event object for the keydown event
Source:
Returns:
whether modifierKeys are valid for the event
Type
boolean

(static) removeListeners(elem)

Removes the Tab Override event listeners from the specified element. Hooks: removeListeners - passed the element from which the listeners will be removed.
Parameters:
Name Type Description
elem Element the element from which the listeners will be removed
Source:

Type Definitions

handlerObj

Type:
  • Object
Properties:
Name Type Description
type string the event type
handler function the handler function - passed an Event object
Source:

listenersObj

Type:
  • Object
Properties:
Name Type Description
add function Adds all the event listeners to the specified element
remove function Removes all the event listeners from the specified element
Source: